lopata 0.1.29 → 0.1.30

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
  SHA256:
3
- metadata.gz: e277eccafc077953963f9f6d44543df7c7d7aac695d7871f1a3f3000cfe0685c
4
- data.tar.gz: 30964380cf628255caa9be854b55809c2c7ac503127ec0791fd563660b8c7384
3
+ metadata.gz: 81374a685539cc6f8c2b4fe190415fa94ff330ebdcc44615a78209c0a8848080
4
+ data.tar.gz: b5b230a64668f227eb6954d4e618d2780c4e6f00255a67a824bb4036acc578e7
5
5
  SHA512:
6
- metadata.gz: a5716169ab5b7379c999bfeef4a45bf41df5ab7f3c9b3274352c6753fc5e1d0e218e6158a2c86e74704931f832b2ed5a7b49a3886afd3beb2104701beaa903b2
7
- data.tar.gz: c1eb1c3a3396f3040f72a0133f530214ab49262f92b1c465f0d6f3ed8b0507be59f6eb252a614748ce995e16306f5fa53f4a7aaa5a8d4e3b1122e812e93958fd
6
+ metadata.gz: f1744e95c43d68bc6785406eb80943f3d51afcf5ac7e876771fa036946eb25140cd99f1748edcbaf614fcdc8371344e493a8570927c57865ae02e57d657e56ff
7
+ data.tar.gz: eb4799fa86d2a0f66540ee4be8e2f67aa9ad2602bf1a3ba4b5fca39069a654a80b64caf1a36e4b33d4e1c33945d78dd11d37bb2c69a35a1712dcbe382df4d32d
@@ -68,6 +68,7 @@ class Lopata::Scenario
68
68
  def initialize(title, metadata = {})
69
69
  @title = title
70
70
  @base_metadata = metadata
71
+ @top = Lopata::GroupExecution.new(Lopata::TopStep.new(title, metadata: base_metadata), nil, steps: [])
71
72
  setup
72
73
  end
73
74
 
@@ -82,7 +83,10 @@ class Lopata::Scenario
82
83
  end
83
84
 
84
85
  def run
85
- setup unless @scenario # for second run if need
86
+ unless @scenario # for second run if need
87
+ setup
88
+ top.reset_status
89
+ end
86
90
  world.notify_observers(:scenario_started, self)
87
91
  run_step(top)
88
92
  world.notify_observers(:scenario_finished, self)
@@ -91,7 +95,6 @@ class Lopata::Scenario
91
95
 
92
96
  def setup
93
97
  @scenario = Lopata::Scenario.new(self)
94
- @top = Lopata::GroupExecution.new(Lopata::TopStep.new(title, metadata: base_metadata), nil, steps: [])
95
98
  @current_step = @top
96
99
  end
97
100
 
@@ -164,7 +167,6 @@ class Lopata::Scenario
164
167
 
165
168
  def cleanup
166
169
  @scenario = nil
167
- @top = nil
168
170
  @current_step = nil
169
171
  end
170
172
  end
data/lib/lopata/step.rb CHANGED
@@ -113,8 +113,12 @@ module Lopata
113
113
  def initialize(step, parent, condition: nil)
114
114
  @step = step
115
115
  @parent = parent
116
- @status = :not_runned
117
116
  @condition = condition
117
+ reset_status
118
+ end
119
+
120
+ def reset_status
121
+ @status = :not_runned
118
122
  end
119
123
 
120
124
  def group?
@@ -205,6 +209,12 @@ module Lopata
205
209
  @let_methods = {}
206
210
  end
207
211
 
212
+ def reset_status
213
+ super
214
+ return unless @steps
215
+ @steps.each(&:reset_status)
216
+ end
217
+
208
218
  def group?
209
219
  true
210
220
  end
@@ -1,6 +1,6 @@
1
1
  module Lopata
2
2
  # @private
3
3
  module Version
4
- STRING = '0.1.29'
4
+ STRING = '0.1.30'
5
5
  end
6
6
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lopata
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.29
4
+ version: 0.1.30
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexey Volochnev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-02-16 00:00:00.000000000 Z
11
+ date: 2024-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty
@@ -58,28 +58,28 @@ dependencies:
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '3.1'
61
+ version: '9.1'
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
- version: '3.1'
68
+ version: '9.1'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: aruba
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '1.0'
75
+ version: '2.2'
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
- version: '1.0'
82
+ version: '2.2'
83
83
  description: Functional acceptance testing
84
84
  email: alexey.volochnev@gmail.com
85
85
  executables:
@@ -138,5 +138,5 @@ requirements: []
138
138
  rubygems_version: 3.2.15
139
139
  signing_key:
140
140
  specification_version: 4
141
- summary: lopata-0.1.29
141
+ summary: lopata-0.1.30
142
142
  test_files: []