simplecov 0.10.0 → 0.11.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -7
- data/.rspec +3 -1
- data/.rubocop.yml +6 -5
- data/CHANGELOG.md +16 -2
- data/Gemfile +14 -14
- data/README.md +28 -12
- data/Rakefile +5 -8
- data/features/config_formatters.feature +1 -1
- data/features/config_tracked_files.feature +29 -0
- data/features/step_definitions/transformers.rb +1 -1
- data/features/support/env.rb +6 -3
- data/lib/simplecov.rb +19 -2
- data/lib/simplecov/configuration.rb +24 -4
- data/lib/simplecov/defaults.rb +28 -5
- data/lib/simplecov/file_list.rb +11 -0
- data/lib/simplecov/filter.rb +1 -1
- data/lib/simplecov/formatter/multi_formatter.rb +17 -13
- data/lib/simplecov/result.rb +1 -1
- data/lib/simplecov/source_file.rb +6 -3
- data/lib/simplecov/version.rb +1 -1
- data/spec/1_8_fallbacks_spec.rb +29 -0
- data/spec/command_guesser_spec.rb +46 -0
- data/spec/deleted_source_spec.rb +12 -0
- data/{test → spec}/faked_project/Gemfile +0 -0
- data/{test → spec}/faked_project/Rakefile +0 -0
- data/{test → spec}/faked_project/cucumber.yml +0 -0
- data/{test → spec}/faked_project/features/step_definitions/my_steps.rb +0 -0
- data/{test → spec}/faked_project/features/support/env.rb +0 -0
- data/{test → spec}/faked_project/features/test_stuff.feature +0 -0
- data/{test → spec}/faked_project/lib/faked_project.rb +1 -1
- data/{test → spec}/faked_project/lib/faked_project/framework_specific.rb +0 -0
- data/{test → spec}/faked_project/lib/faked_project/meta_magic.rb +0 -0
- data/{test → spec}/faked_project/lib/faked_project/some_class.rb +0 -0
- data/spec/faked_project/lib/faked_project/untested_class.rb +11 -0
- data/{test → spec}/faked_project/spec/faked_spec.rb +0 -0
- data/{test → spec}/faked_project/spec/forking_spec.rb +0 -0
- data/{test → spec}/faked_project/spec/meta_magic_spec.rb +0 -0
- data/{test → spec}/faked_project/spec/some_class_spec.rb +0 -0
- data/{test → spec}/faked_project/spec/spec_helper.rb +0 -0
- data/{test → spec}/faked_project/test/faked_test.rb +0 -0
- data/{test → spec}/faked_project/test/meta_magic_test.rb +0 -0
- data/{test → spec}/faked_project/test/some_class_test.rb +0 -0
- data/{test → spec}/faked_project/test/test_helper.rb +0 -0
- data/spec/file_list_spec.rb +48 -0
- data/spec/filters_spec.rb +96 -0
- data/{test → spec}/fixtures/app/controllers/sample_controller.rb +0 -0
- data/{test → spec}/fixtures/app/models/user.rb +0 -0
- data/{test → spec}/fixtures/deleted_source_sample.rb +0 -0
- data/{test → spec}/fixtures/frameworks/rspec_bad.rb +0 -0
- data/{test → spec}/fixtures/frameworks/rspec_good.rb +0 -0
- data/{test → spec}/fixtures/frameworks/testunit_bad.rb +0 -0
- data/{test → spec}/fixtures/frameworks/testunit_good.rb +0 -0
- data/{test → spec}/fixtures/iso-8859.rb +0 -0
- data/{test → spec}/fixtures/resultset1.rb +0 -0
- data/{test → spec}/fixtures/resultset2.rb +0 -0
- data/{test → spec}/fixtures/sample.rb +0 -0
- data/{test → spec}/fixtures/utf-8.rb +0 -0
- data/{test → spec}/helper.rb +3 -7
- data/spec/merge_helpers_spec.rb +108 -0
- data/spec/result_spec.rb +207 -0
- data/spec/return_codes_spec.rb +37 -0
- data/spec/source_file_line_spec.rb +153 -0
- data/spec/source_file_spec.rb +75 -0
- metadata +163 -149
- data/test/shoulda_macros.rb +0 -19
- data/test/test_1_8_fallbacks.rb +0 -31
- data/test/test_command_guesser.rb +0 -19
- data/test/test_deleted_source.rb +0 -14
- data/test/test_file_list.rb +0 -23
- data/test/test_filters.rb +0 -94
- data/test/test_merge_helpers.rb +0 -112
- data/test/test_result.rb +0 -175
- data/test/test_return_codes.rb +0 -41
- data/test/test_source_file.rb +0 -73
- data/test/test_source_file_line.rb +0 -106
@@ -0,0 +1,75 @@
|
|
1
|
+
require "helper"
|
2
|
+
|
3
|
+
describe SimpleCov::SourceFile do
|
4
|
+
COVERAGE_FOR_SAMPLE_RB = [nil, 1, 1, 1, nil, nil, 1, 0, nil, nil, nil, nil, nil, nil, nil, nil]
|
5
|
+
context "a source file initialized with some coverage data" do
|
6
|
+
subject do
|
7
|
+
SimpleCov::SourceFile.new(source_fixture("sample.rb"), COVERAGE_FOR_SAMPLE_RB)
|
8
|
+
end
|
9
|
+
|
10
|
+
it "has a filename" do
|
11
|
+
expect(subject.filename).not_to be_nil
|
12
|
+
end
|
13
|
+
|
14
|
+
it "has source equal to src" do
|
15
|
+
expect(subject.src).to eq(subject.source)
|
16
|
+
end
|
17
|
+
|
18
|
+
it "has source_lines equal to lines" do
|
19
|
+
expect(subject.lines).to eq(subject.source_lines)
|
20
|
+
end
|
21
|
+
|
22
|
+
it "has 16 source lines" do
|
23
|
+
expect(subject.lines.count).to eq(16)
|
24
|
+
end
|
25
|
+
|
26
|
+
it "has all source lines of type SimpleCov::SourceFile::Line" do
|
27
|
+
subject.lines.each do |line|
|
28
|
+
expect(line).to be_a SimpleCov::SourceFile::Line
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
it "has 'class Foo' as line(2).source" do
|
33
|
+
expect(subject.line(2).source).to eq("class Foo\n")
|
34
|
+
end
|
35
|
+
|
36
|
+
it "returns lines number 2, 3, 4, 7 for covered_lines" do
|
37
|
+
expect(subject.covered_lines.map(&:line)).to eq([2, 3, 4, 7])
|
38
|
+
end
|
39
|
+
|
40
|
+
it "returns lines number 8 for missed_lines" do
|
41
|
+
expect(subject.missed_lines.map(&:line)).to eq([8])
|
42
|
+
end
|
43
|
+
|
44
|
+
it "returns lines number 1, 5, 6, 9, 10, 11, 15, 16 for never_lines" do
|
45
|
+
expect(subject.never_lines.map(&:line)).to eq([1, 5, 6, 9, 10, 11, 15, 16])
|
46
|
+
end
|
47
|
+
|
48
|
+
it "returns line numbers 12, 13, 14 for skipped_lines" do
|
49
|
+
expect(subject.skipped_lines.map(&:line)).to eq([12, 13, 14])
|
50
|
+
end
|
51
|
+
|
52
|
+
it "has 80% covered_percent" do
|
53
|
+
expect(subject.covered_percent).to eq(80.0)
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
context "simulating potential Ruby 1.9 defect -- see Issue #56" do
|
58
|
+
subject do
|
59
|
+
SimpleCov::SourceFile.new(source_fixture("sample.rb"), COVERAGE_FOR_SAMPLE_RB + [nil])
|
60
|
+
end
|
61
|
+
|
62
|
+
it "has 16 source lines regardless of extra data in coverage array" do
|
63
|
+
# Do not litter test output with known warning
|
64
|
+
capture_stderr { expect(subject.lines.count).to eq(16) }
|
65
|
+
end
|
66
|
+
|
67
|
+
it "prints a warning to stderr if coverage array contains more data than lines in the file" do
|
68
|
+
captured_output = capture_stderr do
|
69
|
+
subject.lines
|
70
|
+
end
|
71
|
+
|
72
|
+
expect(captured_output).to match(/^Warning: coverage data provided/)
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end if SimpleCov.usable?
|
metadata
CHANGED
@@ -1,70 +1,84 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: simplecov
|
3
|
-
version:
|
4
|
-
version: 0.
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.11.0
|
5
5
|
platform: ruby
|
6
|
-
authors:
|
6
|
+
authors:
|
7
7
|
- Christoph Olszowka
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
- !ruby/object:Gem::Dependency
|
15
|
-
type: :runtime
|
16
|
-
version_requirements: &id001 !ruby/object:Gem::Requirement
|
17
|
-
requirements:
|
18
|
-
- - ~>
|
19
|
-
- !ruby/object:Gem::Version
|
20
|
-
version: "1.8"
|
21
|
-
requirement: *id001
|
22
|
-
prerelease: false
|
11
|
+
date: 2015-11-29 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
23
14
|
name: json
|
24
|
-
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.8'
|
25
20
|
type: :runtime
|
26
|
-
version_requirements: &id003 !ruby/object:Gem::Requirement
|
27
|
-
requirements:
|
28
|
-
- - ~>
|
29
|
-
- *id002
|
30
|
-
requirement: *id003
|
31
21
|
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.8'
|
27
|
+
- !ruby/object:Gem::Dependency
|
32
28
|
name: simplecov-html
|
33
|
-
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.10.0
|
34
34
|
type: :runtime
|
35
|
-
version_requirements: &id004 !ruby/object:Gem::Requirement
|
36
|
-
requirements:
|
37
|
-
- - ~>
|
38
|
-
- !ruby/object:Gem::Version
|
39
|
-
version: 1.1.0
|
40
|
-
requirement: *id004
|
41
35
|
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.10.0
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
42
|
name: docile
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
version: "1.9"
|
50
|
-
requirement: *id005
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 1.1.0
|
48
|
+
type: :runtime
|
51
49
|
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 1.1.0
|
55
|
+
- !ruby/object:Gem::Dependency
|
52
56
|
name: bundler
|
53
|
-
|
54
|
-
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '1.9'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '1.9'
|
69
|
+
description: Code coverage for Ruby 1.9+ with a powerful configuration library and
|
70
|
+
automatic merging of coverage across test suites
|
71
|
+
email:
|
55
72
|
- christoph at olszowka de
|
56
73
|
executables: []
|
57
|
-
|
58
74
|
extensions: []
|
59
|
-
|
60
75
|
extra_rdoc_files: []
|
61
|
-
|
62
|
-
|
63
|
-
- .
|
64
|
-
- .
|
65
|
-
- .
|
66
|
-
- .
|
67
|
-
- .yardopts
|
76
|
+
files:
|
77
|
+
- ".gitignore"
|
78
|
+
- ".rspec"
|
79
|
+
- ".rubocop.yml"
|
80
|
+
- ".travis.yml"
|
81
|
+
- ".yardopts"
|
68
82
|
- CHANGELOG.md
|
69
83
|
- CONTRIBUTING.md
|
70
84
|
- Gemfile
|
@@ -85,6 +99,7 @@ files:
|
|
85
99
|
- features/config_profiles.feature
|
86
100
|
- features/config_project_name.feature
|
87
101
|
- features/config_styles.feature
|
102
|
+
- features/config_tracked_files.feature
|
88
103
|
- features/cucumber_basic.feature
|
89
104
|
- features/maximum_coverage_drop.feature
|
90
105
|
- features/merging_test_unit_and_rspec.feature
|
@@ -130,77 +145,75 @@ files:
|
|
130
145
|
- lib/simplecov/source_file.rb
|
131
146
|
- lib/simplecov/version.rb
|
132
147
|
- simplecov.gemspec
|
133
|
-
-
|
134
|
-
-
|
135
|
-
-
|
136
|
-
-
|
137
|
-
-
|
138
|
-
-
|
139
|
-
-
|
140
|
-
-
|
141
|
-
-
|
142
|
-
-
|
143
|
-
-
|
144
|
-
-
|
145
|
-
-
|
146
|
-
-
|
147
|
-
-
|
148
|
-
-
|
149
|
-
-
|
150
|
-
-
|
151
|
-
-
|
152
|
-
-
|
153
|
-
-
|
154
|
-
- test/
|
155
|
-
-
|
156
|
-
-
|
157
|
-
-
|
158
|
-
-
|
159
|
-
-
|
160
|
-
-
|
161
|
-
-
|
162
|
-
-
|
163
|
-
-
|
164
|
-
-
|
165
|
-
-
|
166
|
-
-
|
167
|
-
-
|
168
|
-
-
|
169
|
-
-
|
170
|
-
-
|
171
|
-
-
|
172
|
-
-
|
173
|
-
-
|
174
|
-
-
|
175
|
-
-
|
148
|
+
- spec/1_8_fallbacks_spec.rb
|
149
|
+
- spec/command_guesser_spec.rb
|
150
|
+
- spec/deleted_source_spec.rb
|
151
|
+
- spec/faked_project/Gemfile
|
152
|
+
- spec/faked_project/Rakefile
|
153
|
+
- spec/faked_project/cucumber.yml
|
154
|
+
- spec/faked_project/features/step_definitions/my_steps.rb
|
155
|
+
- spec/faked_project/features/support/env.rb
|
156
|
+
- spec/faked_project/features/test_stuff.feature
|
157
|
+
- spec/faked_project/lib/faked_project.rb
|
158
|
+
- spec/faked_project/lib/faked_project/framework_specific.rb
|
159
|
+
- spec/faked_project/lib/faked_project/meta_magic.rb
|
160
|
+
- spec/faked_project/lib/faked_project/some_class.rb
|
161
|
+
- spec/faked_project/lib/faked_project/untested_class.rb
|
162
|
+
- spec/faked_project/spec/faked_spec.rb
|
163
|
+
- spec/faked_project/spec/forking_spec.rb
|
164
|
+
- spec/faked_project/spec/meta_magic_spec.rb
|
165
|
+
- spec/faked_project/spec/some_class_spec.rb
|
166
|
+
- spec/faked_project/spec/spec_helper.rb
|
167
|
+
- spec/faked_project/test/faked_test.rb
|
168
|
+
- spec/faked_project/test/meta_magic_test.rb
|
169
|
+
- spec/faked_project/test/some_class_test.rb
|
170
|
+
- spec/faked_project/test/test_helper.rb
|
171
|
+
- spec/file_list_spec.rb
|
172
|
+
- spec/filters_spec.rb
|
173
|
+
- spec/fixtures/app/controllers/sample_controller.rb
|
174
|
+
- spec/fixtures/app/models/user.rb
|
175
|
+
- spec/fixtures/deleted_source_sample.rb
|
176
|
+
- spec/fixtures/frameworks/rspec_bad.rb
|
177
|
+
- spec/fixtures/frameworks/rspec_good.rb
|
178
|
+
- spec/fixtures/frameworks/testunit_bad.rb
|
179
|
+
- spec/fixtures/frameworks/testunit_good.rb
|
180
|
+
- spec/fixtures/iso-8859.rb
|
181
|
+
- spec/fixtures/resultset1.rb
|
182
|
+
- spec/fixtures/resultset2.rb
|
183
|
+
- spec/fixtures/sample.rb
|
184
|
+
- spec/fixtures/utf-8.rb
|
185
|
+
- spec/helper.rb
|
186
|
+
- spec/merge_helpers_spec.rb
|
187
|
+
- spec/result_spec.rb
|
188
|
+
- spec/return_codes_spec.rb
|
189
|
+
- spec/source_file_line_spec.rb
|
190
|
+
- spec/source_file_spec.rb
|
176
191
|
homepage: http://github.com/colszowka/simplecov
|
177
|
-
licenses:
|
192
|
+
licenses:
|
178
193
|
- MIT
|
179
194
|
metadata: {}
|
180
|
-
|
181
195
|
post_install_message:
|
182
196
|
rdoc_options: []
|
183
|
-
|
184
|
-
require_paths:
|
197
|
+
require_paths:
|
185
198
|
- lib
|
186
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
187
|
-
requirements:
|
199
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
200
|
+
requirements:
|
188
201
|
- - ">="
|
189
|
-
- !ruby/object:Gem::Version
|
202
|
+
- !ruby/object:Gem::Version
|
190
203
|
version: 1.8.7
|
191
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
192
|
-
requirements:
|
204
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
205
|
+
requirements:
|
193
206
|
- - ">="
|
194
|
-
- !ruby/object:Gem::Version
|
195
|
-
version:
|
207
|
+
- !ruby/object:Gem::Version
|
208
|
+
version: '0'
|
196
209
|
requirements: []
|
197
|
-
|
198
210
|
rubyforge_project:
|
199
|
-
rubygems_version: 2.4.
|
211
|
+
rubygems_version: 2.4.5
|
200
212
|
signing_key:
|
201
213
|
specification_version: 4
|
202
|
-
summary: Code coverage for Ruby 1.9+ with a powerful configuration library and automatic
|
203
|
-
|
214
|
+
summary: Code coverage for Ruby 1.9+ with a powerful configuration library and automatic
|
215
|
+
merging of coverage across test suites
|
216
|
+
test_files:
|
204
217
|
- features/config_autoload.feature
|
205
218
|
- features/config_command_name.feature
|
206
219
|
- features/config_coverage_dir.feature
|
@@ -211,6 +224,7 @@ test_files:
|
|
211
224
|
- features/config_profiles.feature
|
212
225
|
- features/config_project_name.feature
|
213
226
|
- features/config_styles.feature
|
227
|
+
- features/config_tracked_files.feature
|
214
228
|
- features/cucumber_basic.feature
|
215
229
|
- features/maximum_coverage_drop.feature
|
216
230
|
- features/merging_test_unit_and_rspec.feature
|
@@ -234,46 +248,46 @@ test_files:
|
|
234
248
|
- features/test_unit_groups_using_filter_class.feature
|
235
249
|
- features/test_unit_without_simplecov.feature
|
236
250
|
- features/unicode_compatiblity.feature
|
237
|
-
-
|
238
|
-
-
|
239
|
-
-
|
240
|
-
-
|
241
|
-
-
|
242
|
-
-
|
243
|
-
-
|
244
|
-
-
|
245
|
-
-
|
246
|
-
-
|
247
|
-
-
|
248
|
-
-
|
249
|
-
-
|
250
|
-
-
|
251
|
-
-
|
252
|
-
-
|
253
|
-
-
|
254
|
-
-
|
255
|
-
-
|
256
|
-
-
|
257
|
-
-
|
258
|
-
- test/
|
259
|
-
-
|
260
|
-
-
|
261
|
-
-
|
262
|
-
-
|
263
|
-
-
|
264
|
-
-
|
265
|
-
-
|
266
|
-
-
|
267
|
-
-
|
268
|
-
-
|
269
|
-
-
|
270
|
-
-
|
271
|
-
-
|
272
|
-
-
|
273
|
-
-
|
274
|
-
-
|
275
|
-
-
|
276
|
-
-
|
277
|
-
-
|
278
|
-
-
|
279
|
-
-
|
251
|
+
- spec/1_8_fallbacks_spec.rb
|
252
|
+
- spec/command_guesser_spec.rb
|
253
|
+
- spec/deleted_source_spec.rb
|
254
|
+
- spec/faked_project/Gemfile
|
255
|
+
- spec/faked_project/Rakefile
|
256
|
+
- spec/faked_project/cucumber.yml
|
257
|
+
- spec/faked_project/features/step_definitions/my_steps.rb
|
258
|
+
- spec/faked_project/features/support/env.rb
|
259
|
+
- spec/faked_project/features/test_stuff.feature
|
260
|
+
- spec/faked_project/lib/faked_project.rb
|
261
|
+
- spec/faked_project/lib/faked_project/framework_specific.rb
|
262
|
+
- spec/faked_project/lib/faked_project/meta_magic.rb
|
263
|
+
- spec/faked_project/lib/faked_project/some_class.rb
|
264
|
+
- spec/faked_project/lib/faked_project/untested_class.rb
|
265
|
+
- spec/faked_project/spec/faked_spec.rb
|
266
|
+
- spec/faked_project/spec/forking_spec.rb
|
267
|
+
- spec/faked_project/spec/meta_magic_spec.rb
|
268
|
+
- spec/faked_project/spec/some_class_spec.rb
|
269
|
+
- spec/faked_project/spec/spec_helper.rb
|
270
|
+
- spec/faked_project/test/faked_test.rb
|
271
|
+
- spec/faked_project/test/meta_magic_test.rb
|
272
|
+
- spec/faked_project/test/some_class_test.rb
|
273
|
+
- spec/faked_project/test/test_helper.rb
|
274
|
+
- spec/file_list_spec.rb
|
275
|
+
- spec/filters_spec.rb
|
276
|
+
- spec/fixtures/app/controllers/sample_controller.rb
|
277
|
+
- spec/fixtures/app/models/user.rb
|
278
|
+
- spec/fixtures/deleted_source_sample.rb
|
279
|
+
- spec/fixtures/frameworks/rspec_bad.rb
|
280
|
+
- spec/fixtures/frameworks/rspec_good.rb
|
281
|
+
- spec/fixtures/frameworks/testunit_bad.rb
|
282
|
+
- spec/fixtures/frameworks/testunit_good.rb
|
283
|
+
- spec/fixtures/iso-8859.rb
|
284
|
+
- spec/fixtures/resultset1.rb
|
285
|
+
- spec/fixtures/resultset2.rb
|
286
|
+
- spec/fixtures/sample.rb
|
287
|
+
- spec/fixtures/utf-8.rb
|
288
|
+
- spec/helper.rb
|
289
|
+
- spec/merge_helpers_spec.rb
|
290
|
+
- spec/result_spec.rb
|
291
|
+
- spec/return_codes_spec.rb
|
292
|
+
- spec/source_file_line_spec.rb
|
293
|
+
- spec/source_file_spec.rb
|
data/test/shoulda_macros.rb
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
module ShouldaMacros
|
2
|
-
def should_be(boolean_flag)
|
3
|
-
should "be #{boolean_flag}" do
|
4
|
-
assert_equal true, subject.send(boolean_flag)
|
5
|
-
end
|
6
|
-
end
|
7
|
-
|
8
|
-
def should_not_be(boolean_flag)
|
9
|
-
should "not be #{boolean_flag}" do
|
10
|
-
assert_equal false, subject.send(boolean_flag)
|
11
|
-
end
|
12
|
-
end
|
13
|
-
|
14
|
-
def should_have(attr_name, expectation)
|
15
|
-
should "have #{attr_name} == #{expectation.inspect}" do
|
16
|
-
assert_equal expectation, subject.send(attr_name)
|
17
|
-
end
|
18
|
-
end
|
19
|
-
end
|