togls 3.0.0.pre.rc.6 → 3.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2ee73b04334051fd4cfa74b24dd639181dd80433
4
- data.tar.gz: a28ffbf8cfa7968d31d755f250ba287f3ec4ad05
3
+ metadata.gz: 57f9da9b9163c2c792b5ae4b4d5cedddc062aafc
4
+ data.tar.gz: 04695884191198149f1fb1e0f24cdb3af74b5ad5
5
5
  SHA512:
6
- metadata.gz: e5d9044189ee0e1ea1f19ce740da3bef438f01d4e0ae8b462b72d0a25eaa0db6cfc5f4c71efced54b2e4d2d3aa8aa5fc6486beb525575b26cfb69f4b59f9ab99
7
- data.tar.gz: ee82fe7033ff9de9b91e062ff395886b8167897f0853d25bc8448ef92f6d3c45eece901478cceb1f88014b2264e01535022eb937b9ee7df9668b37e116a8f0dd
6
+ metadata.gz: de6ac856a247749d71f013232a34b3c9f74742773544f16e37b6de50500f3b3bc13492b6ed2ea20bca1d5c1f99b821a58e23746a94318cd1bfea711b1adf310f
7
+ data.tar.gz: 60d11783f2863f1998d39c9c3825e7d3a28f11796d38e6a8cfc46f577cd4fe15dc2b1ea34037222cdb4a31f35656082d529e7c599713bfa36b4f3069b27c96d8
data/CHANGELOG.md CHANGED
@@ -10,6 +10,9 @@ that you can set version constraints properly.
10
10
 
11
11
  #### [Unreleased] - now
12
12
 
13
+ #### [v3.0.0] - 2016-10-19
14
+
15
+ * `Changed`: `Togls.logger` over to the `optional_logger` gem
13
16
  * `Changed`: Rules to be identified by an abstract given string id
14
17
  * `Changed`: Rule and Rule Type management to be global under Togls
15
18
  * `Changed`: The testing interface to allow for contract enforcement in tests
data/README.md CHANGED
@@ -169,7 +169,7 @@ based on group membership.
169
169
  ```ruby
170
170
  # Create a group rule so the feature is on if the user is a member of
171
171
  # the group.
172
- alpha_testers = Togls.rule(:group, ["user1@email.com", "user2@example.com"], target_type: :user_email_address)
172
+ alpha_testers = Togls.rule(:alpha_testers, :group, ["user1@email.com", "user2@example.com"], target_type: :user_email_address)
173
173
 
174
174
  Togls.release do
175
175
  feature(:new_contact_form, "use new contact form", target_type: :user_email_address).on(alpha_testers)
@@ -221,7 +221,7 @@ in the example above and it would look something like the following:
221
221
  ```ruby
222
222
  # Create a group rule so the feature is on if the user is a member of
223
223
  # the group.
224
- alpha_testers = Togls.rule(:group, [1, 23, 42, 83], :user_id)
224
+ alpha_testers = Togls.rule(:alpha_testers, :group, [1, 23, 42, 83], :user_id)
225
225
 
226
226
  Togls.release do
227
227
  feature(:new_contact_form, "use new contact form", :user_id).on(alpha_testers)
data/lib/togls.rb CHANGED
@@ -1,3 +1,4 @@
1
+ require 'optional_logger'
1
2
  require 'togls/version'
2
3
  require 'togls/errors'
3
4
  require 'togls/helpers'
@@ -24,7 +25,6 @@ require 'togls/toggle'
24
25
  require 'togls/null_toggle'
25
26
  require 'togls/rule'
26
27
  require 'togls/rules'
27
- require 'logger'
28
28
  require 'togls/rule_manager'
29
29
  require 'togls/feature_toggle_registry_manager'
30
30
  require 'togls/default_feature_target_type_manager'
@@ -34,6 +34,7 @@ require 'togls/default_feature_target_type_manager'
34
34
  # Togls is the primary interface to the out of the box toggle registry. It is
35
35
  # the namespace the DSL is exposed under.
36
36
  module Togls
37
+ include OptionalLogger::LoggerManagement
37
38
  include RuleManager
38
39
  include FeatureToggleRegistryManager
39
40
  include DefaultFeatureTargetTypeManager
@@ -28,10 +28,6 @@ module Togls
28
28
  Toggler.new(release_toggle_registry.instance_variable_get(:@toggle_repository), release_toggle_registry.get(key))
29
29
  end
30
30
 
31
- def logger
32
- @logger ||= Logger.new(STDOUT)
33
- end
34
-
35
31
  def enable_test_mode
36
32
  @previous_release_toggle_registry = @release_toggle_registry
37
33
  @release_toggle_registry = test_toggle_registry
data/lib/togls/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Togls
2
- VERSION = '3.0.0-rc.6'.freeze
2
+ VERSION = '3.0.0'.freeze
3
3
  end
data/togls.gemspec CHANGED
@@ -25,8 +25,9 @@ Gem::Specification.new do |spec|
25
25
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
26
26
  spec.require_paths = ['lib']
27
27
 
28
+ spec.add_dependency 'optional_logger', '~> 1.1'
28
29
  spec.add_development_dependency 'bundler', '~> 1.9'
29
30
  spec.add_development_dependency 'rake', '~> 10.0'
30
- spec.add_development_dependency 'rspec', '~> 3.4'
31
+ spec.add_development_dependency 'rspec', '~> 3.5'
31
32
  spec.add_development_dependency 'pry', '~> 0.10'
32
33
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: togls
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0.pre.rc.6
4
+ version: 3.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Miller
@@ -10,8 +10,22 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2016-06-29 00:00:00.000000000 Z
13
+ date: 2016-10-19 00:00:00.000000000 Z
14
14
  dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: optional_logger
17
+ requirement: !ruby/object:Gem::Requirement
18
+ requirements:
19
+ - - "~>"
20
+ - !ruby/object:Gem::Version
21
+ version: '1.1'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ requirements:
26
+ - - "~>"
27
+ - !ruby/object:Gem::Version
28
+ version: '1.1'
15
29
  - !ruby/object:Gem::Dependency
16
30
  name: bundler
17
31
  requirement: !ruby/object:Gem::Requirement
@@ -46,14 +60,14 @@ dependencies:
46
60
  requirements:
47
61
  - - "~>"
48
62
  - !ruby/object:Gem::Version
49
- version: '3.4'
63
+ version: '3.5'
50
64
  type: :development
51
65
  prerelease: false
52
66
  version_requirements: !ruby/object:Gem::Requirement
53
67
  requirements:
54
68
  - - "~>"
55
69
  - !ruby/object:Gem::Version
56
- version: '3.4'
70
+ version: '3.5'
57
71
  - !ruby/object:Gem::Dependency
58
72
  name: pry
59
73
  requirement: !ruby/object:Gem::Requirement
@@ -141,9 +155,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
141
155
  version: '0'
142
156
  required_rubygems_version: !ruby/object:Gem::Requirement
143
157
  requirements:
144
- - - ">"
158
+ - - ">="
145
159
  - !ruby/object:Gem::Version
146
- version: 1.3.1
160
+ version: '0'
147
161
  requirements: []
148
162
  rubyforge_project:
149
163
  rubygems_version: 2.5.1