belly 0.5.1 → 0.5.2
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/belly.gemspec +1 -1
- data/lib/belly/cli/rerun.rb +3 -3
- data/lib/belly/client/hub_proxy.rb +3 -1
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.5.
|
1
|
+
0.5.2
|
data/belly.gemspec
CHANGED
data/lib/belly/cli/rerun.rb
CHANGED
@@ -19,9 +19,9 @@ module Belly
|
|
19
19
|
end
|
20
20
|
|
21
21
|
def run(ui)
|
22
|
-
Belly.hub.get_failing_scenarios_for_project_named(Belly.config.project)
|
23
|
-
|
24
|
-
|
22
|
+
scenarios = Belly.hub.get_failing_scenarios_for_project_named(Belly.config.project)
|
23
|
+
todos = scenarios.map { |scenario| "#{scenario["file_name"]}:#{scenario["line_number"]}" }
|
24
|
+
todos.sort.each { |todo| puts todo }
|
25
25
|
end
|
26
26
|
end
|
27
27
|
end
|
@@ -12,7 +12,9 @@ module Belly::Client
|
|
12
12
|
|
13
13
|
def get_failing_scenarios_for_project_named(project_name)
|
14
14
|
project_id = get_project_id_by_name(project_name)
|
15
|
-
|
15
|
+
rerun_statuses = [:pending, :undefined, :failed]
|
16
|
+
status_querystring = rerun_statuses.map { |s| "status[]=#{s}"}.join("&")
|
17
|
+
response = request(:get, "/projects/#{project_id}/cucumber_scenarios.json?#{status_querystring}")
|
16
18
|
JSON.parse(response)["cucumber_scenarios"]
|
17
19
|
end
|
18
20
|
|