statesman 0.6.0 → 0.6.1
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eb317c62d61044bf3d15ec90a14682f330f4ea86
|
4
|
+
data.tar.gz: df1622719c738cfdafd5925042a0ba8c0c4d612c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce715eb5662eb4758d9d637d0575d5cec80859b859400699f783088ec64cdad1a2a661cad2d816e8e14fc03f7b91ec4e4305b64d973eaad959c2112d0ea573b3
|
7
|
+
data.tar.gz: e649cc276449930c9e8615707cf993572a090635e3cdaea838d82c77f825a880243c644a368a76522b7da2c9debb2656d978e71e92538ef52240b74781fe24a3
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,7 @@
|
|
1
|
+
## v 0.6.1 21 May 2014
|
2
|
+
*Fixes*
|
3
|
+
- Fixes an issue where the wrong transition was passed to after_transition callbacks for the second and subsequent transition of a given state machine (patch by [@alan](https://github.com/alan))
|
4
|
+
|
1
5
|
## v0.6.0, 19 May 2014
|
2
6
|
*Additions*
|
3
7
|
- Generators now handle namespaced classes (patch by [@hrmrebecca](https://github.com/hrmrebecca))
|
data/lib/statesman/version.rb
CHANGED
@@ -29,6 +29,7 @@ shared_examples_for "an adapter" do |adapter_class, transition_class|
|
|
29
29
|
describe "#create" do
|
30
30
|
let(:from) { :x }
|
31
31
|
let(:to) { :y }
|
32
|
+
let(:there) { :z }
|
32
33
|
let(:create) { adapter.create(from, to) }
|
33
34
|
subject { -> { create } }
|
34
35
|
|
@@ -71,6 +72,16 @@ shared_examples_for "an adapter" do |adapter_class, transition_class|
|
|
71
72
|
end.once
|
72
73
|
adapter.create(from, to)
|
73
74
|
end
|
75
|
+
|
76
|
+
it "exposes the new transition for subsequent transitions" do
|
77
|
+
adapter.create(from, to)
|
78
|
+
|
79
|
+
observer.should_receive(:execute).with do
|
80
|
+
|phase, from_state, to_state, transition|
|
81
|
+
expect(adapter.last).to eq(transition) if phase == :after
|
82
|
+
end.once
|
83
|
+
adapter.create(to, there)
|
84
|
+
end
|
74
85
|
end
|
75
86
|
|
76
87
|
context "with metadata" do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: statesman
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Harry Marr
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-05-
|
12
|
+
date: 2014-05-21 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|