juncture 0.1.4 → 0.2.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: cfbc1fc326d6601300f5eb27f6bec268fb8e8e38
4
- data.tar.gz: 8b34ea800a6c03e0a8faf8db8f11b6b1875d3de3
3
+ metadata.gz: 334eeda4fd5ac4533665e2f56e2d98311902cf40
4
+ data.tar.gz: 26658f25464242cc2ecce2cb6489128f487bc869
5
5
  SHA512:
6
- metadata.gz: 3b65cbd6412036d639bcd012b0a494cde8e96e513ee37ccd3163424341c236ddd487437cf7844843ad0d80206f9b8d2b72ef8a5857fadc9a51691a82ed163e85
7
- data.tar.gz: b9cbffdd404fee593417cb61ff26c3f5fa4258079c73e2596ad8a294d96bb3d9f004b56a007829d9c666b7d69d993d51af16c9fa0c6963bc78e20aa86a1afffe
6
+ metadata.gz: 83f11dbe3ebfdc6c4bdf31587b9a15e2515b24f8faa60789a2d0615323f9ba213abad9bad93cca898b7b82b187c3150fb12bfc6152404d2752efd955f170560f
7
+ data.tar.gz: a42d4ab9311aeb39342506f608b3448694719ab289423289e800844c4d970d6c1d16d6b3e7b5a071ceb3fcb0ed34ebb63ba100d43d1815ad03f23474e19c38c2
@@ -43,19 +43,19 @@ class Juncture
43
43
  end
44
44
 
45
45
  def <(value)
46
- @states[index+1..-1].include? value
46
+ index < @states.index(value)
47
47
  end
48
48
 
49
49
  def <=(value)
50
- @states[index..-1].include? value
50
+ index <= @states.index(value)
51
51
  end
52
52
 
53
53
  def >(value)
54
- @states[0..index-1].include? value
54
+ index > @states.index(value)
55
55
  end
56
56
 
57
57
  def >=(value)
58
- @states[0..index].include? value
58
+ index >= @states.index(value)
59
59
  end
60
60
 
61
61
  private
@@ -1,4 +1,4 @@
1
1
  class Juncture
2
- VERSION = "0.1.4".freeze
3
- DATE = "2014-02-10".freeze
4
- end
2
+ VERSION = "0.2.0".freeze
3
+ DATE = "2016-12-20".freeze
4
+ end
@@ -79,72 +79,72 @@ describe Juncture do
79
79
  describe '#==' do
80
80
  it 'returns true if matching' do
81
81
  temp = Juncture.new 1, 2, 3, default: 2
82
- expect(temp == 2).to be_true
82
+ expect(temp == 2).to be true
83
83
  end
84
84
 
85
85
  it 'returns false if not matching' do
86
86
  temp = Juncture.new 1, 2, 3, default: 2
87
- expect(temp == 1).to be_false
87
+ expect(temp == 1).to be false
88
88
  end
89
89
  end
90
90
 
91
91
  describe '#===' do
92
92
  it 'returns true if matching' do
93
93
  temp = Juncture.new 1, 2, 3, default: 2
94
- expect(temp === 2).to be_true
94
+ expect(temp === 2).to be true
95
95
  end
96
96
 
97
97
  it 'returns false if not matching' do
98
98
  temp = Juncture.new 1, 2, 3, default: 2
99
- expect(temp === 1).to be_false
99
+ expect(temp === 1).to be false
100
100
  end
101
101
  end
102
102
 
103
103
  describe '#<' do
104
104
  it 'returns true if matching' do
105
105
  temp = Juncture.new 1, 2, 3, default: 2
106
- expect(temp < 3).to be_true
106
+ expect(temp < 3).to be true
107
107
  end
108
108
 
109
109
  it 'returns false if not matching' do
110
110
  temp = Juncture.new 1, 2, 3, default: 2
111
- expect(temp < 2).to be_false
111
+ expect(temp < 2).to be false
112
112
  end
113
113
  end
114
114
 
115
115
  describe '#<=' do
116
116
  it 'returns true if matching' do
117
117
  temp = Juncture.new 1, 2, 3, default: 2
118
- expect(temp <= 2).to be_true
118
+ expect(temp <= 2).to be true
119
119
  end
120
120
 
121
121
  it 'returns false if not matching' do
122
122
  temp = Juncture.new 1, 2, 3, default: 2
123
- expect(temp <= 1).to be_false
123
+ expect(temp <= 1).to be false
124
124
  end
125
125
  end
126
126
 
127
127
  describe '#>' do
128
128
  it 'returns true if matching' do
129
129
  temp = Juncture.new 1, 2, 3, default: 2
130
- expect(temp > 1).to be_true
130
+ expect(temp > 1).to be true
131
131
  end
132
132
 
133
133
  it 'returns false if not matching' do
134
134
  temp = Juncture.new 1, 2, 3, default: 2
135
- expect(temp > 2).to be_false
135
+ expect(temp > 2).to be false
136
136
  end
137
137
  end
138
138
 
139
139
  describe '#>=' do
140
140
  it 'returns true if matching' do
141
141
  temp = Juncture.new 1, 2, 3, default: 2
142
- expect(temp >= 2).to be_true
142
+ expect(temp >= 2).to be true
143
143
  end
144
144
 
145
145
  it 'returns false if not matching' do
146
146
  temp = Juncture.new 1, 2, 3, default: 2
147
- expect(temp >= 3).to be_false
147
+ expect(temp >= 3).to be false
148
148
  end
149
149
  end
150
150
 
@@ -4,10 +4,10 @@ Coveralls.wear!
4
4
  require 'juncture'
5
5
 
6
6
  RSpec.configure do |config|
7
- config.color_enabled = true
7
+ config.color = true
8
8
  config.formatter = :documentation
9
9
  end
10
10
 
11
11
  def fixture_path
12
12
  File.expand_path("../fixtures/", __FILE__)
13
- end
13
+ end
metadata CHANGED
@@ -1,69 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: juncture
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Slaughter
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-02-10 00:00:00.000000000 Z
11
+ date: 2016-12-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
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: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: yard
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: coveralls
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
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
54
  version: '0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rspec
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
  description: A State object that can be queried
@@ -88,21 +88,20 @@ require_paths:
88
88
  - lib
89
89
  required_ruby_version: !ruby/object:Gem::Requirement
90
90
  requirements:
91
- - - '>='
91
+ - - ">="
92
92
  - !ruby/object:Gem::Version
93
93
  version: '0'
94
94
  required_rubygems_version: !ruby/object:Gem::Requirement
95
95
  requirements:
96
- - - '>='
96
+ - - ">="
97
97
  - !ruby/object:Gem::Version
98
98
  version: '0'
99
99
  requirements: []
100
100
  rubyforge_project:
101
- rubygems_version: 2.2.2
101
+ rubygems_version: 2.5.1
102
102
  signing_key:
103
103
  specification_version: 4
104
104
  summary: Simple state object
105
105
  test_files:
106
106
  - spec/juncture_spec.rb
107
107
  - spec/spec_helper.rb
108
- has_rdoc: