deterministic 0.13.1 → 0.14.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: 120b61f2caf3653ca63fc4bca59908c8c3add91b
4
- data.tar.gz: 2813dd0b90f301a5afcbc7861e446c3bdc507f15
3
+ metadata.gz: fe29459fee3d92f463a0acaa8e70cf765c57117f
4
+ data.tar.gz: 487e54e8a8957da68a1e5c1e9e857db6aed572bb
5
5
  SHA512:
6
- metadata.gz: d3195c0fbd1f114843e7003e84b9e24ba129933986ef948f44f19be83202719148b44554d27146acd0addd728aab98bb265356ea1d14e8338b8eaee705bdd91e
7
- data.tar.gz: 721194e06a0618864efffcf079f6cc4220c58b3e0a962e7f2c43186d01e2bcc8825d34999c7c8a4abe8270bd6153901d30dd46393f7e8327a14bdb640a95f094
6
+ metadata.gz: 5ada388430cee5f44676ca39a125ee6ada3790934b791df1d119e7519ad58dbb45b42146e99fc5da833e56b198642ea2063c43a4ef364830d0aa6702002bfd11
7
+ data.tar.gz: f0bb1742c625e01e6f5143afefab1e8c0a3c6cf8a91b5f573bb35538eee6f5a61aee4b3c0dd934144f3290f7020ed8b74d4bcf3662bed5442b79b62ea4ab264e
data/HISTORY.md CHANGED
@@ -1,3 +1,10 @@
1
+ ## v0.14.0
2
+
3
+ - Add `Result#+`
4
+ - Alias pipe with << for left association
5
+ - Make the None convenience wrapper always return instance
6
+ - Add global convenience typdef for Success, Failure
7
+
1
8
  ## v0.13.0
2
9
 
3
10
  - Add `Option#value_to_a`
data/README.md CHANGED
@@ -59,14 +59,14 @@ Failure(1).bind { |v| Success(v - 1) } # => Success(0)
59
59
  Maps a `Success` with the value `a` to another `Result` with the value `b`. It works like `#bind` but only on `Success`.
60
60
 
61
61
  ```ruby
62
- Success(1).map { |n| n + 1 } # => Success(2)
63
- Failure(0).map { |n| n + 1 } # => Failure(0)
62
+ Success(1).map { |n| Success(n + 1) } # => Success(2)
63
+ Failure(0).map { |n| Success(n + 1) } # => Failure(0)
64
64
  ```
65
65
  Maps a `Failure` with the value `a` to another `Result` with the value `b`. It works like `#bind` but only on `Failure`.
66
66
 
67
67
  ```ruby
68
- Failure(1).map_err { |n| n + 1 } # => Success(2)
69
- Success(0).map_err { |n| n + 1 } # => Success(0)
68
+ Failure(1).map_err { |n| Success(n + 1) } # => Success(2)
69
+ Success(0).map_err { |n| Success(n + 1) } # => Success(0)
70
70
  ```
71
71
 
72
72
  ```ruby
data/Rakefile CHANGED
@@ -1 +1,6 @@
1
1
  require "bundler/gem_tasks"
2
+ require 'rspec/core/rake_task'
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
@@ -20,7 +20,7 @@ Gem::Specification.new do |spec|
20
20
 
21
21
  spec.add_development_dependency "bundler", "~> 1.3"
22
22
  spec.add_development_dependency "rake"
23
- spec.add_development_dependency "rspec", "~>3.0.0.beta2"
23
+ spec.add_development_dependency "rspec", ">= 3"
24
24
  spec.add_development_dependency "guard"
25
25
  spec.add_development_dependency "guard-bundler"
26
26
  spec.add_development_dependency "guard-rspec"
@@ -1,5 +1,3 @@
1
- include Deterministic
2
-
3
1
  module Deterministic
4
2
  module CoreExt
5
3
  module Result
@@ -79,7 +79,14 @@ module Deterministic
79
79
  end
80
80
 
81
81
  class None < Option
82
- class << self; public :new; end
82
+ class << self
83
+ public :new
84
+
85
+ def instance
86
+ @instance ||= new
87
+ end
88
+ end
89
+
83
90
  def initialize(*args)
84
91
  @value = self
85
92
  end
@@ -107,6 +114,7 @@ module_function
107
114
  Option::Some.new(value)
108
115
  end
109
116
 
110
- None = Deterministic::Option::None.new
117
+ Some = Deterministic::Option::Some
118
+ None = Deterministic::Option::None.instance
111
119
  end
112
120
  # p Deterministic::Option::Some::Match.new(.methods
@@ -40,6 +40,7 @@ module Deterministic
40
40
  end
41
41
 
42
42
  alias :** :pipe
43
+ alias :<< :pipe
43
44
 
44
45
  # `pipe(self: Result(a), op: |Result(a)| -> b) -> Result(a)`
45
46
  # Replaces `Success a` with `Result b`. If a `Failure` is passed as argument, it is ignored.
@@ -49,14 +50,7 @@ module Deterministic
49
50
  other
50
51
  end
51
52
 
52
- # `and_then(self: Success(a), op: |a| -> Result(b)) -> Result(b)`
53
- # Replaces `Success a` with the result of the block. If a `Failure` is passed as argument, it is ignored.
54
- def and_then(&block)
55
- return self if failure?
56
- bind(&block)
57
- end
58
-
59
- # `or(self: Failure(a), other: Result(b)) -> Result(b)`
53
+ # `or(self: Failure(a), other: Result(b)) -> Result(b)`
60
54
  # Replaces `Failure a` with `Result`. If a `Failure` is passed as argument, it is ignored.
61
55
  def or(other)
62
56
  return self if success?
@@ -64,13 +58,6 @@ module Deterministic
64
58
  return other
65
59
  end
66
60
 
67
- # `or_else(self: Failure(a), op: |a| -> Result(b)) -> Result(b)`
68
- # Replaces `Failure a` with the result of the block. If a `Success` is passed as argument, it is ignored.
69
- def or_else(&block)
70
- return self if success?
71
- bind(&block)
72
- end
73
-
74
61
  # `map(self: Success(a), op: |a| -> Result(b)) -> Result(b)`
75
62
  # Maps a `Success` with the value `a` to another `Result` with the value `b`. It works like `#bind` but only on `Success`.
76
63
  def map(proc=nil, &block)
@@ -79,6 +66,7 @@ module Deterministic
79
66
  end
80
67
 
81
68
  alias :>> :map
69
+ alias :and_then :map
82
70
 
83
71
  # `map_err(self: Failure(a), op: |a| -> Result(b)) -> Result(b)`
84
72
  # Maps a `Failure` with the value `a` to another `Result` with the value `b`. It works like `#bind` but only on `Failure`.
@@ -87,26 +75,40 @@ module Deterministic
87
75
  bind(proc || block)
88
76
  end
89
77
 
78
+ alias :or_else :map_err
79
+
90
80
  # `pipe(self: Result(a), op: |Result(a)| -> b) -> Result(a)`
91
81
  # Executes the block passed, but completely ignores its result. If an error is raised within the block it will **NOT** be catched.
92
82
  def try(proc=nil, &block)
93
83
  map(proc, &block)
94
84
  rescue => err
95
- Failure(err)
85
+ Result::Failure.new(err)
86
+ end
87
+
88
+ # `+(self: Result(a), other: Result(a)) -> Result(a -> a)`
89
+ # Add the inner values of two Result
90
+ def +(other)
91
+ raise Deterministic::Monad::NotMonadError, "Expected #{other.inspect} to be an Result" unless other.is_a? Result
92
+ match {
93
+ success -> (_) { other.success? } { |s| Result::Success.new(s + other.value)}
94
+ failure -> (_) { other.failure? } { |f| Result::Failure.new(f + other.value)}
95
+ success { other } # implied other.failure?
96
+ failure { self } # implied other.success?
97
+ }
96
98
  end
97
99
 
98
100
  alias :>= :try
99
-
101
+
100
102
  class Failure < Result
101
103
  class << self; public :new; end
102
104
  end
103
-
105
+
104
106
  class Success < Result
105
107
  class << self; public :new; end
106
108
  end
107
109
  end
108
110
 
109
- module_function
111
+ module_function
110
112
  def Success(value)
111
113
  Result::Success.new(value)
112
114
  end
@@ -114,4 +116,7 @@ module_function
114
116
  def Failure(value)
115
117
  Result::Failure.new(value)
116
118
  end
119
+
120
+ Success = Result::Success
121
+ Failure = Result::Failure
117
122
  end
@@ -1,3 +1,3 @@
1
1
  module Deterministic
2
- VERSION = "0.13.1"
2
+ VERSION = "0.14.0"
3
3
  end
@@ -0,0 +1,63 @@
1
+ require 'spec_helper'
2
+
3
+ module Deterministic
4
+ module Procify
5
+ def py(m, *args)
6
+ args.count > 0 ? method(m).to_proc.curry[*args] : method(m)
7
+ end
8
+ end
9
+ end
10
+
11
+ class BookingController
12
+ include Deterministic
13
+ include Deterministic::Procify
14
+
15
+ Context = Struct.new(:booking, :ability, :format)
16
+
17
+ def index(id, format=:html)
18
+ get_booking(id) << log(:booking) >>
19
+ py(:ability) << log(:ability) >>
20
+ py(:present, format) << log(:presenter) >>
21
+ py(:render) << log(:render)
22
+ end
23
+
24
+ def log(step)
25
+ ->(data) { p [step, data] }
26
+ end
27
+
28
+ def ability(ctx)
29
+ ctx.ability = {} #Ability.new(@booking)
30
+ Success(ctx)
31
+ end
32
+
33
+ def present(format, ctx)
34
+ ctx.format = format
35
+
36
+ Success(ctx)
37
+ end
38
+
39
+ def render(ctx)
40
+ send(ctx.format, ctx)
41
+ end
42
+
43
+ def html(ctx)
44
+ Success(ctx)
45
+ end
46
+
47
+ def get_booking(id)
48
+ ctx = Context.new
49
+ ctx.booking = {ref_anixe: id}
50
+ Success(ctx)
51
+ # @booking = @bms.booking_by_id(id)
52
+ # rescue BSON::InvalidObjectId => ex
53
+ # @booking = nil
54
+ # @ui.error(404, ex.message)
55
+ end
56
+ end
57
+
58
+ describe BookingController do
59
+ it "does something" do
60
+ bc = BookingController.new
61
+ bc.index('1234', :html)
62
+ end
63
+ end
@@ -0,0 +1,114 @@
1
+ require 'spec_helper'
2
+
3
+ class Logger
4
+ alias :m :method
5
+
6
+ def initialize(repository)
7
+ @repository = repository
8
+ end
9
+
10
+ def log(item)
11
+ validate(item) >> m(:transform) >= m(:save)
12
+ end
13
+
14
+ private
15
+ attr_reader :repository
16
+
17
+ def validate(item)
18
+ return Failure(["Item cannot be empty"]) if item.blank?
19
+ return Failure(["Item must be a Hash"]) unless item.is_a?(Hash)
20
+
21
+ validate_required_params(item).match {
22
+ none { Success(item) }
23
+ some { |errors| Failure(errors) }
24
+ }
25
+ end
26
+
27
+ def transform(params)
28
+ ttl = params.delete(:ttl)
29
+ params.merge!(_ttl: ttl) unless ttl.nil?
30
+ Success(params)
31
+ end
32
+
33
+ def save(item)
34
+ Success(repository.bulk_insert([item]))
35
+ end
36
+
37
+ def validate_required_params(params)
38
+ required_params = %w(date tenant contract user facility short data)
39
+ Option.any?(required_params
40
+ .select{|key| Option.some?(params[key.to_sym]).none? }
41
+ .map{|key| "#{key} is required"}
42
+ )
43
+ end
44
+ end
45
+
46
+ class Ensure
47
+ include Deterministic
48
+ include Deterministic::Monad
49
+ None = Deterministic::Option::None.instance
50
+
51
+ attr_accessor :value
52
+
53
+ def method_missing(m, *args)
54
+ validator_m = "#{m}!".to_sym
55
+ super unless respond_to? validator_m
56
+ send(validator_m, *args).map { |v| Some([Error.new(m, v)])}
57
+ end
58
+
59
+ class Error
60
+ attr_accessor :name, :value
61
+ def initialize(name, value)
62
+ @name, @value = name, value
63
+ end
64
+
65
+ def inspect
66
+ "#{@name}(#{@value.inspect})"
67
+ end
68
+ end
69
+
70
+ def not_empty!
71
+ value.nil? || value.empty? ? Some(value) : None
72
+ end
73
+
74
+ def is_a!(type)
75
+ value.is_a?(type) ? None : Some({obj: value, actual: value.class, expected: type})
76
+ end
77
+
78
+ def has_key!(key)
79
+ value.has_key?(key) ? None : Some(key)
80
+ end
81
+ end
82
+
83
+ class Validator < Ensure
84
+
85
+ def date_is_one!
86
+ value[:date] == 1 ? None : Some({actual: value[:date], expected: 1})
87
+ end
88
+
89
+ def required_params!
90
+ params = %w(date tenant contract user facility short data)
91
+ params.inject(None) { |errors, param|
92
+ errors + (value[:param].nil? || value[:param].empty? ? Some([param]) : None)
93
+ }
94
+ end
95
+
96
+ def call
97
+ not_empty + is_a(Array) + None + has_key(:tenant) + Some("error").value_to_a + date_is_one + required_params
98
+ end
99
+
100
+ end
101
+
102
+ describe Ensure do
103
+ # None = Deterministic::Option::None.instance
104
+
105
+ it "Ensure" do
106
+ params = {date: 2}
107
+
108
+ v = Validator.new(params)
109
+
110
+ errors = v.call
111
+ expect(errors).to be_a Deterministic::Some
112
+ expect(errors.value).not_to be_empty
113
+ end
114
+ end
@@ -0,0 +1,25 @@
1
+ require 'spec_helper'
2
+
3
+ describe 'Class Mixin' do
4
+
5
+ describe 'try' do
6
+ module MyApp
7
+ class Thing
8
+ include Deterministic
9
+
10
+ def run
11
+ Success(11) >= method(:double)
12
+ end
13
+
14
+ def double(num)
15
+ Success(num * 2)
16
+ end
17
+ end
18
+ end
19
+
20
+ it "cleanly mixes into a class" do
21
+ result = MyApp::Thing.new.run
22
+ expect(result).to eq Deterministic::Success.new(22)
23
+ end
24
+ end
25
+ end
@@ -1,8 +1,9 @@
1
1
  require 'spec_helper'
2
2
 
3
- include Deterministic
4
-
5
3
  describe Deterministic::Either do
4
+ include Deterministic
5
+ Either = Deterministic::Either
6
+
6
7
  it "+ does not change operands" do
7
8
  l = Left(1)
8
9
  r = Right(2)
@@ -1,9 +1,12 @@
1
1
  require 'spec_helper'
2
2
  require_relative 'monad_axioms'
3
3
 
4
- include Deterministic
5
4
 
6
5
  describe Deterministic::Option do
6
+ include Deterministic
7
+ Some = Deterministic::Some
8
+ None = Deterministic::None
9
+
7
10
  # nil?
8
11
  specify { expect(described_class.some?(nil)).to eq None }
9
12
  specify { expect(described_class.some?(1)).to be_some }
@@ -23,6 +26,9 @@ describe Deterministic::Option do
23
26
  end
24
27
 
25
28
  describe Deterministic::Option do
29
+ include Deterministic
30
+ Option = Deterministic::Option
31
+
26
32
  # it_behaves_like 'a Monad' do
27
33
  # let(:monad) { described_class }
28
34
  # end
@@ -109,13 +115,17 @@ describe Deterministic::Option do
109
115
  end
110
116
 
111
117
  describe Deterministic::Option::Some do
112
- it_behaves_like 'a Monad' do
118
+ include Deterministic
119
+
120
+ it_behaves_like 'a Monad' do
113
121
  let(:monad) { described_class }
114
122
  end
115
123
  end
116
124
 
117
125
  describe Deterministic::Option::None do
118
- it_behaves_like 'a Monad' do
126
+ include Deterministic
127
+
128
+ it_behaves_like 'a Monad' do
119
129
  let(:monad) { described_class }
120
130
  end
121
131
  end
@@ -2,9 +2,9 @@ require 'spec_helper'
2
2
  require_relative '../monad_axioms'
3
3
  require_relative 'result_shared'
4
4
 
5
- include Deterministic
6
5
 
7
6
  describe Deterministic::Result::Failure do
7
+ include Deterministic
8
8
 
9
9
  it_behaves_like 'a Monad' do
10
10
  let(:monad) { described_class }
@@ -40,6 +40,8 @@ end
40
40
 
41
41
 
42
42
  describe "Chaining" do
43
+ include Deterministic
44
+
43
45
  it "#or" do
44
46
  expect(Success(1).or(Failure(2))).to eq Success(1)
45
47
  expect(Failure(1).or(Success(2))).to eq Success(2)
@@ -1,8 +1,9 @@
1
1
  require 'spec_helper'
2
2
 
3
- include Deterministic
4
3
 
5
4
  describe Deterministic::Result::Match do
5
+ include Deterministic
6
+
6
7
  it "can match Success" do
7
8
  expect(
8
9
  Success(1).match do
@@ -1,14 +1,17 @@
1
1
  require 'spec_helper'
2
2
 
3
- include Deterministic
4
3
 
5
4
  describe Deterministic::Result do
5
+ include Deterministic
6
+
6
7
  context ">> (map)" do
7
8
  specify { expect(Success(0).map { |n| Success(n + 1) }).to eq Success(1) }
8
9
  specify { expect(Failure(0).map { |n| Success(n + 1) }).to eq Failure(0) }
9
10
 
10
11
  it "Failure stops execution" do
11
12
  class ChainUnderTest
13
+ include Deterministic
14
+
12
15
  alias :m :method
13
16
 
14
17
  def call
@@ -72,6 +75,8 @@ describe Deterministic::Result do
72
75
 
73
76
  context "using self as the context for success" do
74
77
  class SelfContextUnderTest
78
+ include Deterministic
79
+
75
80
  def call
76
81
  @step = 0
77
82
  Success(self).
@@ -2,9 +2,9 @@ require 'spec_helper'
2
2
  require_relative '../monad_axioms'
3
3
  require_relative 'result_shared'
4
4
 
5
- include Deterministic
6
5
 
7
6
  describe Deterministic::Result::Success do
7
+ include Deterministic
8
8
 
9
9
  it_behaves_like 'a Monad' do
10
10
  let(:monad) { described_class }
@@ -2,7 +2,22 @@ require 'spec_helper'
2
2
 
3
3
  describe Deterministic::Result do
4
4
  it "can't call Result#new directly" do
5
- expect { described_class.new(1)}
5
+ expect { described_class.new(1)}
6
6
  .to raise_error(NoMethodError, "protected method `new' called for Deterministic::Result:Class")
7
7
  end
8
8
  end
9
+
10
+ describe Deterministic::Result do
11
+ include Deterministic
12
+ describe "+" do
13
+ specify { expect(Success(1) + Success(1)).to eq Success(2) }
14
+ specify { expect(Failure(1) + Failure(1)).to eq Failure(2) }
15
+ specify { expect { Success([1]) + Success(1)}.to raise_error TypeError}
16
+ specify { expect { Failure([1]) + Failure(1)}.to raise_error TypeError}
17
+ specify { expect(Success(1) + Failure(2)).to eq Failure(2) }
18
+ specify { expect(Failure(1) + Success(2)).to eq Failure(1) }
19
+ specify { expect(Success(1) + Failure(2) + Failure(3)).to eq Failure(5) }
20
+ specify { expect(Failure([2]) + Failure([3]) + Success(1)).to eq Failure([2, 3]) }
21
+ specify { expect(Success([1]) + Success([1])).to eq Success([1, 1]) }
22
+ end
23
+ end
metadata CHANGED
@@ -1,111 +1,111 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: deterministic
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.13.1
4
+ version: 0.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Piotr Zolnierek
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-27 00:00:00.000000000 Z
11
+ date: 2014-09-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.3'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: 3.0.0.beta2
47
+ version: '3'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ~>
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: 3.0.0.beta2
54
+ version: '3'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: guard
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: guard-bundler
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - '>='
73
+ - - ">="
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0'
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - '>='
80
+ - - ">="
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: guard-rspec
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - '>='
87
+ - - ">="
88
88
  - !ruby/object:Gem::Version
89
89
  version: '0'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - '>='
94
+ - - ">="
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: simplecov
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
- - - '>='
101
+ - - ">="
102
102
  - !ruby/object:Gem::Version
103
103
  version: '0'
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
- - - '>='
108
+ - - ">="
109
109
  - !ruby/object:Gem::Version
110
110
  version: '0'
111
111
  description: A gem providing failsafe flow
@@ -115,8 +115,8 @@ executables: []
115
115
  extensions: []
116
116
  extra_rdoc_files: []
117
117
  files:
118
- - .gitignore
119
- - .rspec
118
+ - ".gitignore"
119
+ - ".rspec"
120
120
  - Gemfile
121
121
  - Guardfile
122
122
  - HISTORY.md
@@ -137,7 +137,10 @@ files:
137
137
  - lib/deterministic/version.rb
138
138
  - spec/examples/bookings_spec.rb
139
139
  - spec/examples/config_spec.rb
140
+ - spec/examples/controller_spec.rb
141
+ - spec/examples/logger_spec.rb
140
142
  - spec/examples/validate_address_spec.rb
143
+ - spec/lib/deterministic/class_mixin_spec.rb
141
144
  - spec/lib/deterministic/core_ext/object/either_spec.rb
142
145
  - spec/lib/deterministic/core_ext/result_spec.rb
143
146
  - spec/lib/deterministic/either_spec.rb
@@ -163,12 +166,12 @@ require_paths:
163
166
  - lib
164
167
  required_ruby_version: !ruby/object:Gem::Requirement
165
168
  requirements:
166
- - - '>='
169
+ - - ">="
167
170
  - !ruby/object:Gem::Version
168
171
  version: '0'
169
172
  required_rubygems_version: !ruby/object:Gem::Requirement
170
173
  requirements:
171
- - - '>='
174
+ - - ">="
172
175
  - !ruby/object:Gem::Version
173
176
  version: '0'
174
177
  requirements: []
@@ -180,7 +183,10 @@ summary: see above
180
183
  test_files:
181
184
  - spec/examples/bookings_spec.rb
182
185
  - spec/examples/config_spec.rb
186
+ - spec/examples/controller_spec.rb
187
+ - spec/examples/logger_spec.rb
183
188
  - spec/examples/validate_address_spec.rb
189
+ - spec/lib/deterministic/class_mixin_spec.rb
184
190
  - spec/lib/deterministic/core_ext/object/either_spec.rb
185
191
  - spec/lib/deterministic/core_ext/result_spec.rb
186
192
  - spec/lib/deterministic/either_spec.rb