Move feature flag test setup into config (#34124)
This commit is contained in:
parent
dc43699b77
commit
bedf808e02
4 changed files with 24 additions and 19 deletions
8
spec/support/feature_flags.rb
Normal file
8
spec/support/feature_flags.rb
Normal file
|
@ -0,0 +1,8 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
RSpec.configure do |config|
|
||||
config.before(:example, :feature) do |example|
|
||||
feature = example.metadata[:feature]
|
||||
allow(Mastodon::Feature).to receive(:"#{feature}_enabled?").and_return(true)
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue