turnip_formatter 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/rspec/core/formatters/turnip_formatter.rb +7 -34
- data/lib/turnip_formatter/ext/turnip/rspec.rb +2 -0
- data/lib/turnip_formatter/printer/index.rb +29 -0
- data/lib/turnip_formatter/printer/runtime_error.rb +41 -0
- data/lib/turnip_formatter/printer/scenario.rb +20 -0
- data/lib/turnip_formatter/printer/step.rb +34 -0
- data/lib/turnip_formatter/printer/step_extra_args.rb +21 -0
- data/lib/turnip_formatter/printer/tab_feature_statistics.rb +47 -0
- data/lib/turnip_formatter/printer/tab_speed_statistics.rb +34 -0
- data/lib/turnip_formatter/printer/tab_tag_statistics.rb +72 -0
- data/lib/turnip_formatter/printer.rb +34 -0
- data/lib/turnip_formatter/template/exception.erb +9 -25
- data/lib/turnip_formatter/template/index.erb +65 -0
- data/lib/turnip_formatter/template/runtime_exception.erb +16 -0
- data/lib/turnip_formatter/template/scenario.erb +9 -8
- data/lib/turnip_formatter/template/step.erb +4 -0
- data/lib/turnip_formatter/template/tab_feature_statistics.erb +24 -0
- data/lib/turnip_formatter/template/tab_speed_statistics.erb +18 -0
- data/lib/turnip_formatter/template/tab_tag_statistics.erb +24 -0
- data/lib/turnip_formatter/template/turnip_formatter.js +51 -0
- data/lib/turnip_formatter/{formatter.scss → template/turnip_formatter.scss} +0 -0
- data/lib/turnip_formatter/template.rb +21 -254
- data/lib/turnip_formatter/version.rb +1 -1
- data/lib/turnip_formatter.rb +1 -1
- data/spec/rspec/core/formatters/turnip_formatter_spec.rb +11 -28
- data/spec/turnip_formatter/printer/scenario_spec.rb +33 -0
- data/spec/turnip_formatter/printer/step_extra_args_spec.rb +32 -0
- data/spec/turnip_formatter/printer/step_spec.rb +86 -0
- data/spec/turnip_formatter/printer/tab_feature_statistics_spec.rb +83 -0
- data/spec/turnip_formatter/printer/tab_speed_statistics_spec.rb +51 -0
- data/spec/turnip_formatter/printer/tab_tag_statistics_spec.rb +90 -0
- data/spec/turnip_formatter/template_spec.rb +0 -173
- data/turnip_formatter.gemspec +2 -0
- metadata +63 -14
- data/lib/turnip_formatter/formatter.css +0 -205
- data/lib/turnip_formatter/template/scenario_tags.erb +0 -5
- data/lib/turnip_formatter/template/tab/feature_statistics.rb +0 -78
- data/lib/turnip_formatter/template/tab/speed_statistics.rb +0 -61
- data/lib/turnip_formatter/template/tab/tag_statistics.rb +0 -101
- data/spec/turnip_formatter/template/tab/feature_statistics_spec.rb +0 -87
- data/spec/turnip_formatter/template/tab/speed_statistics_spec.rb +0 -56
- data/spec/turnip_formatter/template/tab/tag_statistics_spec.rb +0 -88
@@ -0,0 +1,51 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require 'turnip_formatter/printer/tab_speed_statistics'
|
3
|
+
|
4
|
+
module TurnipFormatter::Printer
|
5
|
+
describe TabSpeedStatistics do
|
6
|
+
include_context 'turnip_formatter scenario setup'
|
7
|
+
include_context 'turnip_formatter standard scenario metadata'
|
8
|
+
|
9
|
+
let :statistics do
|
10
|
+
TurnipFormatter::Printer::TabSpeedStatistics
|
11
|
+
end
|
12
|
+
|
13
|
+
let :passed_scenarios do
|
14
|
+
([example] * 3).map do |ex|
|
15
|
+
TurnipFormatter::Scenario::Pass.new(ex)
|
16
|
+
end.each { |s| s.stub(:run_time).and_return(rand) }
|
17
|
+
end
|
18
|
+
|
19
|
+
describe '.print_out' do
|
20
|
+
it 'should get string as HTML table' do
|
21
|
+
html = statistics.print_out(passed_scenarios)
|
22
|
+
|
23
|
+
passed_scenarios.each do |scenario|
|
24
|
+
tag_scenario_name = "<a href=\"\##{scenario.id}\">#{scenario.name}</a>"
|
25
|
+
tag_run_time = "<span>#{scenario.run_time}</span>"
|
26
|
+
tag_feature_name = "<span>#{scenario.feature_name}</span>"
|
27
|
+
|
28
|
+
expect_match = [
|
29
|
+
'<tr>',
|
30
|
+
"<td>#{tag_feature_name}</td>",
|
31
|
+
"<td>#{tag_scenario_name}</td>",
|
32
|
+
"<td>#{tag_run_time} sec</td>",
|
33
|
+
'</tr>'
|
34
|
+
].join('[[:space:]]+')
|
35
|
+
|
36
|
+
expect(html).to match %r(#{expect_match})
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
describe '.speed_analysis' do
|
42
|
+
it 'should get array of scenario order by run_time' do
|
43
|
+
scenarios = statistics.send(:speed_analysis, passed_scenarios)
|
44
|
+
expect(scenarios).to have(3).elements
|
45
|
+
|
46
|
+
run_time_list = scenarios.map(&:run_time)
|
47
|
+
expect(run_time_list.sort).to eq run_time_list
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
@@ -0,0 +1,90 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require 'turnip_formatter/printer/tab_tag_statistics'
|
3
|
+
|
4
|
+
module TurnipFormatter::Printer
|
5
|
+
describe TabTagStatistics do
|
6
|
+
include_context 'turnip_formatter scenario setup'
|
7
|
+
include_context 'turnip_formatter standard scenario metadata'
|
8
|
+
|
9
|
+
let :base_scenario do
|
10
|
+
TurnipFormatter::Scenario::Pass.new(example)
|
11
|
+
end
|
12
|
+
|
13
|
+
let :scenarios do
|
14
|
+
scenarios = []
|
15
|
+
|
16
|
+
# | tag | scenarios | passed | failed | pending | status |
|
17
|
+
# |-------+-----------+--------+--------+---------+---------|
|
18
|
+
# | none | 1 | 1 | 0 | 0 | status |
|
19
|
+
# | @bar | 2 | 0 | 1 | 1 | failed |
|
20
|
+
# | @foo | 1 | 0 | 1 | 0 | failed |
|
21
|
+
# | @hoge | 1 | 1 | 0 | 1 | pending |
|
22
|
+
|
23
|
+
# Failed scenario have tags @hoge and @fuga
|
24
|
+
scenario = base_scenario.dup
|
25
|
+
scenario.stub(:tags).and_return(['foo', 'bar'])
|
26
|
+
scenario.stub(:status).and_return('failed')
|
27
|
+
scenarios << scenario
|
28
|
+
|
29
|
+
# Passed scenario no have tags
|
30
|
+
scenario = base_scenario.dup
|
31
|
+
scenario.stub(:tags).and_return([])
|
32
|
+
scenario.stub(:status).and_return('passed')
|
33
|
+
scenarios << scenario
|
34
|
+
|
35
|
+
# Passed scenario have tags @hoge
|
36
|
+
scenario = base_scenario.dup
|
37
|
+
scenario.stub(:tags).and_return(['hoge'])
|
38
|
+
scenario.stub(:status).and_return('passed')
|
39
|
+
scenarios << scenario
|
40
|
+
|
41
|
+
# Pending scenario have tags @fuga and @hago
|
42
|
+
scenario = base_scenario.dup
|
43
|
+
scenario.stub(:tags).and_return(['bar', 'hoge'])
|
44
|
+
scenario.stub(:status).and_return('pending')
|
45
|
+
scenarios << scenario
|
46
|
+
end
|
47
|
+
|
48
|
+
let :statistics do
|
49
|
+
TurnipFormatter::Printer::TabTagStatistics
|
50
|
+
end
|
51
|
+
|
52
|
+
let :groups do
|
53
|
+
statistics.send(:group_by_tag, scenarios)
|
54
|
+
end
|
55
|
+
|
56
|
+
describe '.group_by_tag' do
|
57
|
+
it 'should get results sort by tag name' do
|
58
|
+
expect(groups.map(&:first)).to eq ['@bar', '@foo', '@hoge', 'turnip']
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
describe '.tag_analysis' do
|
63
|
+
it 'should get count of each status' do
|
64
|
+
# @bar
|
65
|
+
group = groups[0]
|
66
|
+
res = statistics.send(:tag_analysis, group[0], group[1])
|
67
|
+
expect([res.passed, res.failed, res.pending]).to eq [0, 1, 1]
|
68
|
+
expect(res.status).to eq 'failed'
|
69
|
+
|
70
|
+
# @foo
|
71
|
+
group = groups[1]
|
72
|
+
res = statistics.send(:tag_analysis, group[0], group[1])
|
73
|
+
expect([res.passed, res.failed, res.pending]).to eq [0, 1, 0]
|
74
|
+
expect(res.status).to eq 'failed'
|
75
|
+
|
76
|
+
# @hoge
|
77
|
+
group = groups[2]
|
78
|
+
res = statistics.send(:tag_analysis, group[0], group[1])
|
79
|
+
expect([res.passed, res.failed, res.pending]).to eq [1, 0, 1]
|
80
|
+
expect(res.status).to eq 'pending'
|
81
|
+
|
82
|
+
# no tags (turnip)
|
83
|
+
group = groups[3]
|
84
|
+
res = statistics.send(:tag_analysis, group[0], group[1])
|
85
|
+
expect([res.passed, res.failed, res.pending]).to eq [1, 0, 0]
|
86
|
+
expect(res.status).to eq 'passed'
|
87
|
+
end
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
@@ -2,178 +2,5 @@ require 'spec_helper'
|
|
2
2
|
|
3
3
|
module TurnipFormatter
|
4
4
|
describe Template do
|
5
|
-
let(:template) { ::TurnipFormatter::Template.new }
|
6
|
-
let(:exception_style) { ::TurnipFormatter::StepTemplate::Exception }
|
7
|
-
let(:source_style) { ::TurnipFormatter::StepTemplate::Source }
|
8
|
-
|
9
|
-
describe '#print_scenario_tags' do
|
10
|
-
subject { template.print_scenario_tags(scenario) }
|
11
|
-
|
12
|
-
context 'Step has no tag' do
|
13
|
-
let(:scenario) do
|
14
|
-
scenario = double('scenario')
|
15
|
-
scenario.stub(:tags).and_return([])
|
16
|
-
scenario
|
17
|
-
end
|
18
|
-
|
19
|
-
it { should eq '' }
|
20
|
-
end
|
21
|
-
|
22
|
-
context 'Step has tags' do
|
23
|
-
let(:scenario) do
|
24
|
-
scenario = double('scenario')
|
25
|
-
scenario.stub(:tags).and_return(['hoge', '<b>fuga</b>'])
|
26
|
-
scenario
|
27
|
-
end
|
28
|
-
|
29
|
-
it {
|
30
|
-
should match %r{ul class="tags"}
|
31
|
-
should match %r{<li>@hoge</li>[[:space:]]+<li>@<b>fuga</b></li>}
|
32
|
-
}
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
describe '#step_attr' do
|
37
|
-
let(:passed_step) do
|
38
|
-
step = double
|
39
|
-
step.stub(:attention?).and_return(false)
|
40
|
-
step.should_not_receive(:status)
|
41
|
-
step
|
42
|
-
end
|
43
|
-
|
44
|
-
let(:failed_step) do
|
45
|
-
step = double
|
46
|
-
step.stub(:attention?).and_return(true)
|
47
|
-
step.should_receive(:status) { 'failed' }
|
48
|
-
step
|
49
|
-
end
|
50
|
-
|
51
|
-
it 'should get tag attribute string' do
|
52
|
-
expect(template.send(:step_attr, passed_step)).to eq('class="step"')
|
53
|
-
expect(template.send(:step_attr, failed_step)).to eq('class="step failed"')
|
54
|
-
end
|
55
|
-
end
|
56
|
-
|
57
|
-
context 'Step has arguments' do
|
58
|
-
let(:table) { Turnip::Table.new [] }
|
59
|
-
|
60
|
-
context 'original template' do
|
61
|
-
describe '#step_args' do
|
62
|
-
let(:step) do
|
63
|
-
docs = {}
|
64
|
-
docs[:extra_args] = { klass: nil, value: ['a', table] }
|
65
|
-
docs[source_style] = { klass: source_style, value: 'b' }
|
66
|
-
docs[exception_style] = { klass: exception_style, value: 'c' }
|
67
|
-
|
68
|
-
step = double
|
69
|
-
step.stub(:docs).and_return(docs)
|
70
|
-
step
|
71
|
-
end
|
72
|
-
|
73
|
-
it 'should call corresponding method in step' do
|
74
|
-
template.should_receive(:print_step_multiline).with('a').and_return('extra_args1')
|
75
|
-
template.should_receive(:print_step_outline).with(table).and_return('extra_args2')
|
76
|
-
source_style.should_receive(:build).with('b').and_return('source')
|
77
|
-
exception_style.should_receive(:build).with('c').and_return('exception')
|
78
|
-
expect(template.send(:step_args, step)).to eq("extra_args1\nextra_args2\nsource\nexception")
|
79
|
-
end
|
80
|
-
end
|
81
|
-
end
|
82
|
-
|
83
|
-
context 'custom template' do
|
84
|
-
describe '#step_args' do
|
85
|
-
let(:custom_template_1) do
|
86
|
-
Module.new do
|
87
|
-
def self.build(value)
|
88
|
-
"<html>#{value}</html>"
|
89
|
-
end
|
90
|
-
end
|
91
|
-
end
|
92
|
-
|
93
|
-
let(:custom_template_2) do
|
94
|
-
Module.new do
|
95
|
-
def self.build(value)
|
96
|
-
"<strong>#{value}</strong>"
|
97
|
-
end
|
98
|
-
end
|
99
|
-
end
|
100
|
-
|
101
|
-
let(:step) do
|
102
|
-
step = double
|
103
|
-
step.stub(:docs).and_return(
|
104
|
-
source: { klass: custom_template_1, value: 'aiueo' },
|
105
|
-
exception: { klass: custom_template_2, value: '12345' }
|
106
|
-
)
|
107
|
-
step
|
108
|
-
end
|
109
|
-
|
110
|
-
it 'should call corresponding method in step' do
|
111
|
-
expect(template.send(:step_args, step)).to eq("<html>aiueo</html>\n<strong>12345</strong>")
|
112
|
-
end
|
113
|
-
end
|
114
|
-
end
|
115
|
-
end
|
116
|
-
|
117
|
-
context 'Step has no argument' do
|
118
|
-
describe '#step_args' do
|
119
|
-
let(:step) do
|
120
|
-
step = double
|
121
|
-
step.stub(:docs).and_return({})
|
122
|
-
step
|
123
|
-
end
|
124
|
-
|
125
|
-
it 'should get null string' do
|
126
|
-
template.should_not_receive(:print_step_multiline)
|
127
|
-
template.should_not_receive(:print_step_outline)
|
128
|
-
source_style.should_not_receive(:build)
|
129
|
-
exception_style.should_not_receive(:build)
|
130
|
-
expect(template.send(:step_args, step)).to be_empty
|
131
|
-
end
|
132
|
-
end
|
133
|
-
end
|
134
|
-
|
135
|
-
describe '#print_step_extra_args' do
|
136
|
-
let(:template_stub) do
|
137
|
-
template.tap do |t|
|
138
|
-
template.stub(:print_step_outline).and_return('outline')
|
139
|
-
template.stub(:print_step_multiline).and_return('multiline')
|
140
|
-
end
|
141
|
-
end
|
142
|
-
|
143
|
-
let(:extra_args) do
|
144
|
-
[::Turnip::Table.new([['a']]), 'b']
|
145
|
-
end
|
146
|
-
|
147
|
-
before do
|
148
|
-
template.should_receive(:print_step_outline).and_return('outline')
|
149
|
-
template.should_receive(:print_step_multiline).and_return('multiline')
|
150
|
-
end
|
151
|
-
|
152
|
-
it 'should get string converted from extra_args' do
|
153
|
-
expect(template_stub.send(:print_step_extra_args, extra_args)).to eq("outline\nmultiline")
|
154
|
-
end
|
155
|
-
end
|
156
|
-
|
157
|
-
describe '#print_step_multiline' do
|
158
|
-
let(:string) { 'a<a>a' }
|
159
|
-
subject { template.print_step_multiline(string) }
|
160
|
-
it { should include '<pre class="multiline">a<a>a</pre>' }
|
161
|
-
end
|
162
|
-
|
163
|
-
describe '#print_step_outline' do
|
164
|
-
let(:string) do
|
165
|
-
::Turnip::Table.new([
|
166
|
-
["State", "Money"],
|
167
|
-
["<Tokushima>", "555"],
|
168
|
-
["<Okinawa>", "368"]
|
169
|
-
])
|
170
|
-
end
|
171
|
-
|
172
|
-
subject { template.print_step_outline(string) }
|
173
|
-
|
174
|
-
it { should match %r{<td>State</td>[[:space:]]+<td>Money</td>} }
|
175
|
-
it { should match %r{<td><Tokushima></td>[[:space:]]+<td>555</td>} }
|
176
|
-
it { should match %r{<td><Okinawa></td>[[:space:]]+<td>368</td>} }
|
177
|
-
end
|
178
5
|
end
|
179
6
|
end
|
data/turnip_formatter.gemspec
CHANGED
@@ -20,6 +20,8 @@ Gem::Specification.new do |spec|
|
|
20
20
|
|
21
21
|
spec.add_dependency 'turnip'
|
22
22
|
spec.add_dependency 'sass'
|
23
|
+
spec.add_dependency 'uglifier'
|
24
|
+
spec.add_dependency 'rspec', '~> 2.13.0'
|
23
25
|
spec.add_development_dependency "bundler", "~> 1.3"
|
24
26
|
spec.add_development_dependency "rake"
|
25
27
|
spec.add_development_dependency 'coveralls'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: turnip_formatter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-07-
|
12
|
+
date: 2013-07-10 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: turnip
|
@@ -43,6 +43,38 @@ dependencies:
|
|
43
43
|
- - ! '>='
|
44
44
|
- !ruby/object:Gem::Version
|
45
45
|
version: '0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: uglifier
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
54
|
+
type: :runtime
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: rspec
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
66
|
+
requirements:
|
67
|
+
- - ~>
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: 2.13.0
|
70
|
+
type: :runtime
|
71
|
+
prerelease: false
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ~>
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: 2.13.0
|
46
78
|
- !ruby/object:Gem::Dependency
|
47
79
|
name: bundler
|
48
80
|
requirement: !ruby/object:Gem::Requirement
|
@@ -148,8 +180,15 @@ files:
|
|
148
180
|
- lib/turnip_formatter.rb
|
149
181
|
- lib/turnip_formatter/ext/turnip/builder.rb
|
150
182
|
- lib/turnip_formatter/ext/turnip/rspec.rb
|
151
|
-
- lib/turnip_formatter/
|
152
|
-
- lib/turnip_formatter/
|
183
|
+
- lib/turnip_formatter/printer.rb
|
184
|
+
- lib/turnip_formatter/printer/index.rb
|
185
|
+
- lib/turnip_formatter/printer/runtime_error.rb
|
186
|
+
- lib/turnip_formatter/printer/scenario.rb
|
187
|
+
- lib/turnip_formatter/printer/step.rb
|
188
|
+
- lib/turnip_formatter/printer/step_extra_args.rb
|
189
|
+
- lib/turnip_formatter/printer/tab_feature_statistics.rb
|
190
|
+
- lib/turnip_formatter/printer/tab_speed_statistics.rb
|
191
|
+
- lib/turnip_formatter/printer/tab_tag_statistics.rb
|
153
192
|
- lib/turnip_formatter/scenario.rb
|
154
193
|
- lib/turnip_formatter/scenario/failure.rb
|
155
194
|
- lib/turnip_formatter/scenario/pass.rb
|
@@ -164,19 +203,29 @@ files:
|
|
164
203
|
- lib/turnip_formatter/template.rb
|
165
204
|
- lib/turnip_formatter/template/exception.erb
|
166
205
|
- lib/turnip_formatter/template/exception_backtrace.erb
|
206
|
+
- lib/turnip_formatter/template/index.erb
|
207
|
+
- lib/turnip_formatter/template/runtime_exception.erb
|
167
208
|
- lib/turnip_formatter/template/scenario.erb
|
168
|
-
- lib/turnip_formatter/template/scenario_tags.erb
|
169
209
|
- lib/turnip_formatter/template/section_report.erb
|
210
|
+
- lib/turnip_formatter/template/step.erb
|
170
211
|
- lib/turnip_formatter/template/step_multiline.erb
|
171
212
|
- lib/turnip_formatter/template/step_outline.erb
|
172
|
-
- lib/turnip_formatter/template/
|
173
|
-
- lib/turnip_formatter/template/
|
174
|
-
- lib/turnip_formatter/template/
|
213
|
+
- lib/turnip_formatter/template/tab_feature_statistics.erb
|
214
|
+
- lib/turnip_formatter/template/tab_speed_statistics.erb
|
215
|
+
- lib/turnip_formatter/template/tab_tag_statistics.erb
|
216
|
+
- lib/turnip_formatter/template/turnip_formatter.js
|
217
|
+
- lib/turnip_formatter/template/turnip_formatter.scss
|
175
218
|
- lib/turnip_formatter/version.rb
|
176
219
|
- spec/rspec/core/formatters/turnip_formatter_spec.rb
|
177
220
|
- spec/spec_helper.rb
|
178
221
|
- spec/support/passed.feature
|
179
222
|
- spec/support/shared_context_examples.rb
|
223
|
+
- spec/turnip_formatter/printer/scenario_spec.rb
|
224
|
+
- spec/turnip_formatter/printer/step_extra_args_spec.rb
|
225
|
+
- spec/turnip_formatter/printer/step_spec.rb
|
226
|
+
- spec/turnip_formatter/printer/tab_feature_statistics_spec.rb
|
227
|
+
- spec/turnip_formatter/printer/tab_speed_statistics_spec.rb
|
228
|
+
- spec/turnip_formatter/printer/tab_tag_statistics_spec.rb
|
180
229
|
- spec/turnip_formatter/scenario/failure_spec.rb
|
181
230
|
- spec/turnip_formatter/scenario/pass_spec.rb
|
182
231
|
- spec/turnip_formatter/scenario/pending_spec.rb
|
@@ -185,9 +234,6 @@ files:
|
|
185
234
|
- spec/turnip_formatter/step_spec.rb
|
186
235
|
- spec/turnip_formatter/step_template/exception_spec.rb
|
187
236
|
- spec/turnip_formatter/step_template/source_spec.rb
|
188
|
-
- spec/turnip_formatter/template/tab/feature_statistics_spec.rb
|
189
|
-
- spec/turnip_formatter/template/tab/speed_statistics_spec.rb
|
190
|
-
- spec/turnip_formatter/template/tab/tag_statistics_spec.rb
|
191
237
|
- spec/turnip_formatter/template_spec.rb
|
192
238
|
- turnip_formatter.gemspec
|
193
239
|
homepage: https://github.com/gongo/turnip_formatter
|
@@ -220,6 +266,12 @@ test_files:
|
|
220
266
|
- spec/spec_helper.rb
|
221
267
|
- spec/support/passed.feature
|
222
268
|
- spec/support/shared_context_examples.rb
|
269
|
+
- spec/turnip_formatter/printer/scenario_spec.rb
|
270
|
+
- spec/turnip_formatter/printer/step_extra_args_spec.rb
|
271
|
+
- spec/turnip_formatter/printer/step_spec.rb
|
272
|
+
- spec/turnip_formatter/printer/tab_feature_statistics_spec.rb
|
273
|
+
- spec/turnip_formatter/printer/tab_speed_statistics_spec.rb
|
274
|
+
- spec/turnip_formatter/printer/tab_tag_statistics_spec.rb
|
223
275
|
- spec/turnip_formatter/scenario/failure_spec.rb
|
224
276
|
- spec/turnip_formatter/scenario/pass_spec.rb
|
225
277
|
- spec/turnip_formatter/scenario/pending_spec.rb
|
@@ -228,7 +280,4 @@ test_files:
|
|
228
280
|
- spec/turnip_formatter/step_spec.rb
|
229
281
|
- spec/turnip_formatter/step_template/exception_spec.rb
|
230
282
|
- spec/turnip_formatter/step_template/source_spec.rb
|
231
|
-
- spec/turnip_formatter/template/tab/feature_statistics_spec.rb
|
232
|
-
- spec/turnip_formatter/template/tab/speed_statistics_spec.rb
|
233
|
-
- spec/turnip_formatter/template/tab/tag_statistics_spec.rb
|
234
283
|
- spec/turnip_formatter/template_spec.rb
|
@@ -1,205 +0,0 @@
|
|
1
|
-
body {
|
2
|
-
background-color: #ffffff; }
|
3
|
-
|
4
|
-
div#report {
|
5
|
-
margin: 0 auto;
|
6
|
-
padding: 2em;
|
7
|
-
background: black;
|
8
|
-
color: #509b49; }
|
9
|
-
|
10
|
-
footer {
|
11
|
-
margin: 0 auto;
|
12
|
-
padding: 2em;
|
13
|
-
background: black;
|
14
|
-
color: #509b49;
|
15
|
-
text-align: right; }
|
16
|
-
|
17
|
-
div#main {
|
18
|
-
margin: 0 auto;
|
19
|
-
padding: 2em;
|
20
|
-
background-color: #ffffff; }
|
21
|
-
div#main .ui-tabs-nav {
|
22
|
-
border-width: 0;
|
23
|
-
padding: 0; }
|
24
|
-
div#main .ui-tabs-panel {
|
25
|
-
border: 1px solid #7a7b7d; }
|
26
|
-
|
27
|
-
div#steps-statistics section.scenario {
|
28
|
-
margin: 1em 0em;
|
29
|
-
padding-left: 1em;
|
30
|
-
border: 2px solid green; }
|
31
|
-
div#steps-statistics section.scenario > header {
|
32
|
-
margin: 1em 0em; }
|
33
|
-
div#steps-statistics section.scenario > header:hover {
|
34
|
-
text-decoration: underline;
|
35
|
-
cursor: pointer; }
|
36
|
-
div#steps-statistics section.scenario > header span.scenario_name {
|
37
|
-
font-weight: bold;
|
38
|
-
font-size: 14px; }
|
39
|
-
div#steps-statistics section.scenario > header span.feature_name {
|
40
|
-
font-size: 13px;
|
41
|
-
color: #839496; }
|
42
|
-
div#steps-statistics section.scenario > header span.permalink {
|
43
|
-
margin-right: 1em;
|
44
|
-
font-size: 15px; }
|
45
|
-
div#steps-statistics section.scenario > header span.permalink a {
|
46
|
-
color: #268bd2; }
|
47
|
-
div#steps-statistics section.scenario > ul.tags {
|
48
|
-
font-size: 12px; }
|
49
|
-
div#steps-statistics section.scenario > ul.tags li {
|
50
|
-
color: #839496;
|
51
|
-
display: inline; }
|
52
|
-
div#steps-statistics section.scenario.passed {
|
53
|
-
border-color: #509b49; }
|
54
|
-
div#steps-statistics section.scenario.passed > header .scenario_name {
|
55
|
-
color: #509b49; }
|
56
|
-
div#steps-statistics section.scenario.passed > header .scenario_name:before {
|
57
|
-
content: "\2713\20"; }
|
58
|
-
div#steps-statistics section.scenario.failed {
|
59
|
-
border-color: #ed1c24; }
|
60
|
-
div#steps-statistics section.scenario.failed > header .scenario_name {
|
61
|
-
color: #ed1c24; }
|
62
|
-
div#steps-statistics section.scenario.failed > header .scenario_name:before {
|
63
|
-
content: "\2717\20"; }
|
64
|
-
div#steps-statistics section.scenario.pending {
|
65
|
-
border-color: #d6a921; }
|
66
|
-
div#steps-statistics section.scenario.pending > header .scenario_name {
|
67
|
-
color: #d6a921; }
|
68
|
-
div#steps-statistics section.scenario.pending > header .scenario_name:before {
|
69
|
-
content: "\d8\20"; }
|
70
|
-
div#steps-statistics section.scenario ul.steps {
|
71
|
-
font-size: 12px;
|
72
|
-
list-style-type: none; }
|
73
|
-
div#steps-statistics section.scenario ul.steps li.step {
|
74
|
-
padding: 0.5em;
|
75
|
-
font-weight: bold;
|
76
|
-
margin: 0.5em 0em; }
|
77
|
-
div#steps-statistics section.scenario ul.steps li.step > span {
|
78
|
-
border: 1px solid #509b49;
|
79
|
-
padding: 0.5em;
|
80
|
-
background-color: #eeffee;
|
81
|
-
color: #509b49; }
|
82
|
-
div#steps-statistics section.scenario ul.steps li.step > span:hover {
|
83
|
-
border-width: 3px; }
|
84
|
-
div#steps-statistics section.scenario ul.steps li.step > span ~ * {
|
85
|
-
margin-left: 2em; }
|
86
|
-
div#steps-statistics section.scenario ul.steps li.step.failure {
|
87
|
-
/* skip/pending step style */ }
|
88
|
-
div#steps-statistics section.scenario ul.steps li.step.failure > span {
|
89
|
-
border: 1px solid #ed1c24;
|
90
|
-
padding: 0.5em;
|
91
|
-
background-color: #ffdddd;
|
92
|
-
color: #ed1c24; }
|
93
|
-
div#steps-statistics section.scenario ul.steps li.step.failure > span:hover {
|
94
|
-
border-width: 3px; }
|
95
|
-
div#steps-statistics section.scenario ul.steps li.step.failure > span ~ * {
|
96
|
-
margin-left: 2em; }
|
97
|
-
div#steps-statistics section.scenario ul.steps li.step.failure > div.args {
|
98
|
-
font-size: 11px;
|
99
|
-
padding: 1em;
|
100
|
-
background-color: #ffdddd;
|
101
|
-
border: 1px solid #ed1c24; }
|
102
|
-
div#steps-statistics section.scenario ul.steps li.step.failure ~ li > span {
|
103
|
-
background-color: #dddddd;
|
104
|
-
border-color: #7a7b7d;
|
105
|
-
color: #7a7b7d; }
|
106
|
-
div#steps-statistics section.scenario ul.steps li.step.pending {
|
107
|
-
/* skip/pending step style */ }
|
108
|
-
div#steps-statistics section.scenario ul.steps li.step.pending > span {
|
109
|
-
border: 1px solid #d6a921;
|
110
|
-
padding: 0.5em;
|
111
|
-
background-color: #ffffdd;
|
112
|
-
color: #d6a921; }
|
113
|
-
div#steps-statistics section.scenario ul.steps li.step.pending > span:hover {
|
114
|
-
border-width: 3px; }
|
115
|
-
div#steps-statistics section.scenario ul.steps li.step.pending > span ~ * {
|
116
|
-
margin-left: 2em; }
|
117
|
-
div#steps-statistics section.scenario ul.steps li.step.pending > div.args {
|
118
|
-
font-size: 11px;
|
119
|
-
padding: 1em;
|
120
|
-
background-color: #ffffdd;
|
121
|
-
border: 1px solid #d6a921; }
|
122
|
-
div#steps-statistics section.scenario ul.steps li.step.pending ~ li > span {
|
123
|
-
background-color: #dddddd;
|
124
|
-
border-color: #7a7b7d;
|
125
|
-
color: #7a7b7d; }
|
126
|
-
div#steps-statistics section.scenario ul.steps table.step_outline {
|
127
|
-
margin-top: 2em; }
|
128
|
-
div#steps-statistics section.scenario ul.steps table.step_outline tr:nth-child(odd) {
|
129
|
-
background-color: #ddddcc; }
|
130
|
-
div#steps-statistics section.scenario ul.steps table.step_outline tr:nth-child(even) {
|
131
|
-
background-color: #ccccdd; }
|
132
|
-
div#steps-statistics section.scenario ul.steps table.step_outline td {
|
133
|
-
border: 2px solid black;
|
134
|
-
padding: 0.3em 1em; }
|
135
|
-
div#steps-statistics section.scenario ul.steps pre.multiline {
|
136
|
-
margin-top: 2em;
|
137
|
-
font-size: 13px;
|
138
|
-
color: #586e75; }
|
139
|
-
|
140
|
-
div#speed-statistics table,
|
141
|
-
div#feature-statistics table,
|
142
|
-
div#tag-statistics table {
|
143
|
-
width: 100%;
|
144
|
-
margin: 1em 0em; }
|
145
|
-
div#speed-statistics table thead th,
|
146
|
-
div#feature-statistics table thead th,
|
147
|
-
div#tag-statistics table thead th {
|
148
|
-
border-bottom: 1px solid #7a7b7d; }
|
149
|
-
div#speed-statistics table tbody tr:nth-child(odd),
|
150
|
-
div#feature-statistics table tbody tr:nth-child(odd),
|
151
|
-
div#tag-statistics table tbody tr:nth-child(odd) {
|
152
|
-
background-color: #FFFFFF; }
|
153
|
-
div#speed-statistics table tbody tr:nth-child(even),
|
154
|
-
div#feature-statistics table tbody tr:nth-child(even),
|
155
|
-
div#tag-statistics table tbody tr:nth-child(even) {
|
156
|
-
background-color: #dddddd; }
|
157
|
-
div#speed-statistics table tbody td,
|
158
|
-
div#feature-statistics table tbody td,
|
159
|
-
div#tag-statistics table tbody td {
|
160
|
-
border: 1px solid #7a7b7d;
|
161
|
-
padding: 0.3em 1em; }
|
162
|
-
div#speed-statistics table tbody td.passed,
|
163
|
-
div#feature-statistics table tbody td.passed,
|
164
|
-
div#tag-statistics table tbody td.passed {
|
165
|
-
background-color: #eeffee;
|
166
|
-
color: #509b49; }
|
167
|
-
div#speed-statistics table tbody td.failed,
|
168
|
-
div#feature-statistics table tbody td.failed,
|
169
|
-
div#tag-statistics table tbody td.failed {
|
170
|
-
background-color: #ffdddd;
|
171
|
-
color: #ed1c24; }
|
172
|
-
div#speed-statistics table tbody td.pending,
|
173
|
-
div#feature-statistics table tbody td.pending,
|
174
|
-
div#tag-statistics table tbody td.pending {
|
175
|
-
background-color: #ffffdd;
|
176
|
-
color: #d6a921; }
|
177
|
-
|
178
|
-
div#speed-statistics .tablesorter-header {
|
179
|
-
background-position: center right;
|
180
|
-
background-repeat: no-repeat;
|
181
|
-
cursor: pointer;
|
182
|
-
background-image: url("data:image/gif;base64,R0lGODlhFQAJAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAkAAAIXjI+AywnaYnhUMoqt3gZXPmVg94yJVQAAOw=="); }
|
183
|
-
div#speed-statistics .tablesorter-header.sorter-false {
|
184
|
-
background: none; }
|
185
|
-
div#speed-statistics .tablesorter-headerAsc {
|
186
|
-
background-position: center right;
|
187
|
-
background-repeat: no-repeat;
|
188
|
-
cursor: pointer;
|
189
|
-
background-image: url("data:image/gif;base64,R0lGODlhFQAEAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAQAAAINjI8Bya2wnINUMopZAQA7"); }
|
190
|
-
div#speed-statistics .tablesorter-headerDesc {
|
191
|
-
background-position: center right;
|
192
|
-
background-repeat: no-repeat;
|
193
|
-
cursor: pointer;
|
194
|
-
background-image: url("data:image/gif;base64,R0lGODlhFQAEAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7"); }
|
195
|
-
|
196
|
-
section.exception {
|
197
|
-
margin: 1em 0em;
|
198
|
-
border: 2px solid #268bd2;
|
199
|
-
padding: 2em; }
|
200
|
-
section.exception dt {
|
201
|
-
line-height: 2em;
|
202
|
-
font-size: 15px; }
|
203
|
-
section.exception dd {
|
204
|
-
line-height: 2em;
|
205
|
-
font-size: 14px; }
|