Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Set groups to new registry where needed.

  • Loading branch information...
commit 77ffb591059486388c142cabfcfe68d650e4ba85 1 parent 46f1c66
@jnunemaker authored
View
1  spec/flipper/dsl_spec.rb
@@ -11,6 +11,7 @@
before do
source.clear
+ Flipper.groups = Flipper::Registry.new
end
def feature(name)
View
2  spec/flipper/feature_spec.rb
@@ -28,6 +28,8 @@
let(:percentage_of_random_key) { Flipper::Gates::PercentageOfRandom::Key }
before do
+ Flipper.groups = Flipper::Registry.new
+
Flipper.register(:admins) { |thing| thing.admin? }
Flipper.register(:devs) { |thing| thing.dev? }
View
4 spec/flipper_spec.rb
@@ -1,6 +1,10 @@
require 'helper'
describe Flipper do
+ before do
+ Flipper.groups = Flipper::Registry.new
+ end
+
describe ".groups" do
it "returns a registry instance" do
Flipper.groups.should be_instance_of(Flipper::Registry)
View
1  spec/helper.rb
@@ -24,7 +24,6 @@
config.run_all_when_everything_filtered = true
config.before(:each) do
- Flipper.groups = Flipper::Registry.new
Timecop.return
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.