mutant 0.3.0.beta21 → 0.3.0.beta22
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.
- checksums.yaml +4 -4
- data/.gitignore +37 -6
- data/.rspec +2 -0
- data/.ruby-gemset +1 -0
- data/.travis.yml +13 -7
- data/Gemfile +8 -3
- data/Gemfile.devtools +2 -6
- data/Guardfile +22 -8
- data/README.md +3 -1
- data/Rakefile +3 -0
- data/bin/mutant +4 -3
- data/config/devtools.yml +1 -1
- data/config/flay.yml +1 -1
- data/config/flog.yml +1 -1
- data/config/reek.yml +7 -6
- data/config/rubocop.yml +55 -0
- data/lib/mutant.rb +3 -1
- data/lib/mutant/cache.rb +2 -0
- data/lib/mutant/cli.rb +14 -10
- data/lib/mutant/cli/classifier.rb +22 -10
- data/lib/mutant/cli/classifier/method.rb +14 -15
- data/lib/mutant/cli/classifier/namespace.rb +6 -2
- data/lib/mutant/cli/classifier/scope.rb +3 -1
- data/lib/mutant/color.rb +7 -3
- data/lib/mutant/config.rb +2 -0
- data/lib/mutant/constants.rb +5 -4
- data/lib/mutant/context.rb +2 -0
- data/lib/mutant/context/scope.rb +3 -1
- data/lib/mutant/differ.rb +10 -2
- data/lib/mutant/killer.rb +4 -1
- data/lib/mutant/killer/forked.rb +2 -0
- data/lib/mutant/killer/forking.rb +2 -0
- data/lib/mutant/killer/rspec.rb +19 -3
- data/lib/mutant/killer/static.rb +2 -0
- data/lib/mutant/loader.rb +8 -1
- data/lib/mutant/matcher.rb +2 -0
- data/lib/mutant/matcher/chain.rb +2 -0
- data/lib/mutant/matcher/method.rb +15 -3
- data/lib/mutant/matcher/method/finder.rb +2 -0
- data/lib/mutant/matcher/method/instance.rb +4 -1
- data/lib/mutant/matcher/method/singleton.rb +7 -1
- data/lib/mutant/matcher/methods.rb +3 -1
- data/lib/mutant/matcher/namespace.rb +4 -2
- data/lib/mutant/matcher/scope.rb +2 -0
- data/lib/mutant/mutation.rb +19 -5
- data/lib/mutant/mutation/evil.rb +12 -0
- data/lib/mutant/mutation/filter.rb +2 -0
- data/lib/mutant/mutation/filter/code.rb +3 -1
- data/lib/mutant/mutation/filter/regexp.rb +2 -0
- data/lib/mutant/mutation/filter/whitelist.rb +2 -0
- data/lib/mutant/mutation/neutral.rb +25 -0
- data/lib/mutant/mutator.rb +4 -6
- data/lib/mutant/mutator/node.rb +5 -1
- data/lib/mutant/mutator/node/argument.rb +2 -0
- data/lib/mutant/mutator/node/arguments.rb +2 -0
- data/lib/mutant/mutator/node/begin.rb +2 -0
- data/lib/mutant/mutator/node/block.rb +2 -0
- data/lib/mutant/mutator/node/case.rb +3 -1
- data/lib/mutant/mutator/node/connective/binary.rb +3 -1
- data/lib/mutant/mutator/node/const.rb +2 -0
- data/lib/mutant/mutator/node/define.rb +2 -0
- data/lib/mutant/mutator/node/generic.rb +4 -3
- data/lib/mutant/mutator/node/if.rb +2 -0
- data/lib/mutant/mutator/node/literal.rb +2 -0
- data/lib/mutant/mutator/node/literal/array.rb +2 -0
- data/lib/mutant/mutator/node/literal/boolean.rb +2 -0
- data/lib/mutant/mutator/node/literal/dynamic.rb +2 -0
- data/lib/mutant/mutator/node/literal/fixnum.rb +3 -1
- data/lib/mutant/mutator/node/literal/float.rb +2 -0
- data/lib/mutant/mutator/node/literal/hash.rb +2 -0
- data/lib/mutant/mutator/node/literal/nil.rb +2 -0
- data/lib/mutant/mutator/node/literal/range.rb +2 -1
- data/lib/mutant/mutator/node/literal/regex.rb +2 -0
- data/lib/mutant/mutator/node/literal/string.rb +2 -0
- data/lib/mutant/mutator/node/literal/symbol.rb +5 -1
- data/lib/mutant/mutator/node/masgn.rb +2 -0
- data/lib/mutant/mutator/node/mlhs.rb +2 -0
- data/lib/mutant/mutator/node/named_value/access.rb +2 -0
- data/lib/mutant/mutator/node/named_value/constant_assignment.rb +2 -0
- data/lib/mutant/mutator/node/named_value/variable_assignment.rb +3 -1
- data/lib/mutant/mutator/node/{cbase.rb → noop.rb} +7 -5
- data/lib/mutant/mutator/node/return.rb +2 -0
- data/lib/mutant/mutator/node/send.rb +2 -0
- data/lib/mutant/mutator/node/send/binary.rb +2 -0
- data/lib/mutant/mutator/node/splat.rb +2 -0
- data/lib/mutant/mutator/node/super.rb +2 -0
- data/lib/mutant/mutator/node/when.rb +3 -1
- data/lib/mutant/mutator/node/while.rb +2 -0
- data/lib/mutant/mutator/node/zsuper.rb +2 -0
- data/lib/mutant/mutator/registry.rb +55 -13
- data/lib/mutant/mutator/util.rb +2 -0
- data/lib/mutant/mutator/util/array.rb +3 -1
- data/lib/mutant/mutator/util/symbol.rb +2 -0
- data/lib/mutant/node_helpers.rb +10 -4
- data/lib/mutant/random.rb +2 -0
- data/lib/mutant/reporter.rb +2 -0
- data/lib/mutant/reporter/cli.rb +2 -0
- data/lib/mutant/reporter/cli/printer.rb +2 -0
- data/lib/mutant/reporter/cli/printer/config.rb +5 -2
- data/lib/mutant/reporter/cli/printer/killer.rb +2 -0
- data/lib/mutant/reporter/cli/printer/mutation.rb +13 -6
- data/lib/mutant/reporter/cli/printer/subject.rb +5 -1
- data/lib/mutant/reporter/null.rb +2 -0
- data/lib/mutant/runner.rb +2 -0
- data/lib/mutant/runner/config.rb +2 -0
- data/lib/mutant/runner/mutation.rb +2 -0
- data/lib/mutant/runner/subject.rb +2 -0
- data/lib/mutant/singleton_methods.rb +5 -3
- data/lib/mutant/strategy.rb +2 -0
- data/lib/mutant/strategy/method_expansion.rb +2 -0
- data/lib/mutant/strategy/rspec.rb +2 -0
- data/lib/mutant/strategy/rspec/dm2.rb +2 -0
- data/lib/mutant/strategy/rspec/dm2/lookup.rb +4 -2
- data/lib/mutant/strategy/rspec/dm2/lookup/method.rb +2 -0
- data/lib/mutant/strategy/static.rb +2 -0
- data/lib/mutant/subject.rb +4 -1
- data/lib/mutant/subject/method.rb +2 -0
- data/lib/mutant/subject/method/instance.rb +2 -0
- data/lib/mutant/subject/method/singleton.rb +2 -0
- data/lib/mutant/support/method_object.rb +2 -0
- data/lib/mutant/zombifier.rb +10 -6
- data/mutant.gemspec +11 -10
- data/spec/integration/mutant/rspec_killer_spec.rb +9 -4
- data/spec/integration/mutant/test_mutator_handles_types_spec.rb +3 -1
- data/spec/integration/mutant/zombie_spec.rb +2 -0
- data/spec/shared/method_matcher_behavior.rb +2 -0
- data/spec/shared/mutator_behavior.rb +16 -7
- data/spec/spec_helper.rb +26 -5
- data/spec/support/compress_helper.rb +5 -5
- data/spec/support/ice_nine_config.rb +2 -0
- data/spec/support/rspec.rb +2 -0
- data/spec/support/test_app.rb +2 -0
- data/spec/unit/mutant/class_methods/singleton_subclass_instance_spec.rb +2 -0
- data/spec/unit/mutant/cli/class_methods/new_spec.rb +17 -8
- data/spec/unit/mutant/cli/class_methods/run_spec.rb +10 -2
- data/spec/unit/mutant/cli/classifier/class_methods/build_spec.rb +4 -1
- data/spec/unit/mutant/cli/classifier/method/each_spec.rb +89 -0
- data/spec/unit/mutant/cli/classifier/namespace/flat/each_spec.rb +58 -0
- data/spec/unit/mutant/cli/classifier/namespace/recursive/each_spec.rb +58 -0
- data/spec/unit/mutant/cli/classifier/scope/each_spec.rb +33 -0
- data/spec/unit/mutant/context/root_spec.rb +5 -1
- data/spec/unit/mutant/context/scope/root_spec.rb +2 -0
- data/spec/unit/mutant/context/scope/unqualified_name_spec.rb +2 -0
- data/spec/unit/mutant/differ/class_methods/build_spec.rb +2 -0
- data/spec/unit/mutant/differ/class_methods/colorize_line_spec.rb +2 -0
- data/spec/unit/mutant/differ/diff_spec.rb +67 -5
- data/spec/unit/mutant/killer/rspec/class_methods/new_spec.rb +21 -4
- data/spec/unit/mutant/killer/success_predicate_spec.rb +2 -0
- data/spec/unit/mutant/loader/eval/class_methods/run_spec.rb +12 -5
- data/spec/unit/mutant/matcher/chain/each_spec.rb +2 -0
- data/spec/unit/mutant/matcher/chain/matchers_spec.rb +2 -0
- data/spec/unit/mutant/matcher/each_spec.rb +8 -1
- data/spec/unit/mutant/matcher/method/instance/class_methods/build_spec.rb +4 -2
- data/spec/unit/mutant/matcher/method/instance/each_spec.rb +21 -20
- data/spec/unit/mutant/matcher/method/singleton/each_spec.rb +22 -19
- data/spec/unit/mutant/matcher/methods/instance/each_spec.rb +8 -3
- data/spec/unit/mutant/matcher/methods/singleton/each_spec.rb +8 -3
- data/spec/unit/mutant/matcher/namespace/each_spec.rb +8 -2
- data/spec/unit/mutant/mutator/each_spec.rb +2 -0
- data/spec/unit/mutant/mutator/emit_new_spec.rb +10 -3
- data/spec/unit/mutant/mutator/emit_spec.rb +4 -2
- data/spec/unit/mutant/mutator/node/and_asgn/mutation_spec.rb +26 -0
- data/spec/unit/mutant/mutator/node/begin/mutation_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/block/mutation_spec.rb +4 -2
- data/spec/unit/mutant/mutator/node/block_pass/mutation_spec.rb +14 -0
- data/spec/unit/mutant/mutator/node/break/mutation_spec.rb +15 -0
- data/spec/unit/mutant/mutator/node/case/mutation_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/cbase/mutation_spec.rb +3 -6
- data/spec/unit/mutant/mutator/node/connective/binary/mutation_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/const/mutation_spec.rb +3 -6
- data/spec/unit/mutant/mutator/node/define/mutation_spec.rb +2 -1
- data/spec/unit/mutant/mutator/node/defined_predicate/mutation_spec.rb +10 -0
- data/spec/unit/mutant/mutator/node/dstr/mutation_spec.rb +21 -0
- data/spec/unit/mutant/mutator/node/dsym/mutation_spec.rb +21 -0
- data/spec/unit/mutant/mutator/node/ensure/mutation_spec.rb +15 -0
- data/spec/unit/mutant/mutator/node/if/mutation_spec.rb +2 -1
- data/spec/unit/mutant/mutator/node/literal/array_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/literal/boolean/mutation_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/literal/fixnum_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/literal/float_spec.rb +4 -2
- data/spec/unit/mutant/mutator/node/literal/hash_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/literal/nil_spec.rb +4 -5
- data/spec/unit/mutant/mutator/node/literal/range_spec.rb +8 -8
- data/spec/unit/mutant/mutator/node/literal/regex_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/literal/string_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/literal/symbol_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/masgn/mutation_spec.rb +4 -10
- data/spec/unit/mutant/mutator/node/match_current_line/mutation_spec.rb +20 -0
- data/spec/unit/mutant/mutator/node/named_value/access/mutation_spec.rb +3 -2
- data/spec/unit/mutant/mutator/node/named_value/constant_assignment/mutation_spec.rb +3 -2
- data/spec/unit/mutant/mutator/node/named_value/variable_assignment/mutation_spec.rb +3 -2
- data/spec/unit/mutant/mutator/node/next/mutation_spec.rb +15 -0
- data/spec/unit/mutant/mutator/node/op_assgn/mutation_spec.rb +26 -0
- data/spec/unit/mutant/mutator/node/or_asgn/mutation_spec.rb +26 -0
- data/spec/unit/mutant/mutator/node/redo/mutation_spec.rb +10 -0
- data/spec/unit/mutant/mutator/node/rescue/mutation_spec.rb +24 -0
- data/spec/unit/mutant/mutator/node/restarg/mutation_spec.rb +16 -0
- data/spec/unit/mutant/mutator/node/return/mutation_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/send/mutation_spec.rb +3 -1
- data/spec/unit/mutant/mutator/node/super/mutation_spec.rb +2 -0
- data/spec/unit/mutant/mutator/node/while/mutation_spec.rb +3 -1
- data/spec/unit/mutant/mutator/node/yield/mutation_spec.rb +15 -0
- data/spec/unit/mutant/node_helpers/n_not_spec.rb +2 -0
- data/spec/unit/mutant/runner/config/subjects_spec.rb +6 -2
- data/spec/unit/mutant/runner/config/success_predicate_spec.rb +15 -6
- data/spec/unit/mutant/runner/mutation/killer_spec.rb +3 -1
- data/spec/unit/mutant/runner/subject/success_predicate_spec.rb +15 -8
- data/spec/unit/mutant/strategy/method_expansion/class_methods/run_spec.rb +2 -0
- data/spec/unit/mutant/strategy/rspec/dm2/lookup/method/instance/spec_files_spec.rb +32 -11
- data/spec/unit/mutant/strategy/rspec/dm2/lookup/method/singleton/spec_files_spec.rb +31 -11
- data/spec/unit/mutant/subject/context_spec.rb +2 -0
- data/spec/unit/mutant/subject/mutations_spec.rb +2 -0
- data/spec/unit/mutant/subject/node_spec.rb +2 -0
- data/test_app/lib/test_app.rb +2 -0
- data/test_app/lib/test_app/literal.rb +2 -0
- data/test_app/spec/shared/method_filter_parse_behavior.rb +5 -1
- data/test_app/spec/shared/method_match_behavior.rb +2 -0
- data/test_app/spec/spec_helper.rb +3 -1
- data/test_app/spec/unit/test_app/literal/command_spec.rb +2 -0
- data/test_app/spec/unit/test_app/literal/string_spec.rb +3 -1
- metadata +66 -18
- data/bin/zombie +0 -18
- data/test_app/spec/shared/mutator_behavior.rb +0 -44
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# encoding: utf-8
|
|
2
|
+
|
|
1
3
|
shared_examples_for 'a method filter parse result' do
|
|
2
4
|
before do
|
|
3
5
|
expected_class.stub(:new => response)
|
|
@@ -8,7 +10,9 @@ shared_examples_for 'a method filter parse result' do
|
|
|
8
10
|
it { should be(response) }
|
|
9
11
|
|
|
10
12
|
it 'should initialize method filter with correct arguments' do
|
|
11
|
-
expected_class.should_receive(:new)
|
|
13
|
+
expected_class.should_receive(:new)
|
|
14
|
+
.with(TestApp::Literal, :string)
|
|
15
|
+
.and_return(response)
|
|
12
16
|
subject
|
|
13
17
|
end
|
|
14
18
|
end
|
|
@@ -6,4 +6,6 @@ require 'test_app'
|
|
|
6
6
|
require 'rspec'
|
|
7
7
|
|
|
8
8
|
# require spec support files and shared behavior
|
|
9
|
-
Dir[File.expand_path('../{support,shared}/**/*.rb', __FILE__)].each
|
|
9
|
+
Dir[File.expand_path('../{support,shared}/**/*.rb', __FILE__)].each do |file|
|
|
10
|
+
require file
|
|
11
|
+
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mutant
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.0.
|
|
4
|
+
version: 0.3.0.beta22
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Markus Schirp
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2013-07-
|
|
11
|
+
date: 2013-07-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: parser
|
|
@@ -16,28 +16,28 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - ~>
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: 2.0.0.
|
|
19
|
+
version: 2.0.0.pre3
|
|
20
20
|
type: :runtime
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
24
24
|
- - ~>
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: 2.0.0.
|
|
26
|
+
version: 2.0.0.pre3
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
28
|
name: unparser
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
|
30
30
|
requirements:
|
|
31
31
|
- - ~>
|
|
32
32
|
- !ruby/object:Gem::Version
|
|
33
|
-
version: 0.0.
|
|
33
|
+
version: 0.0.13
|
|
34
34
|
type: :runtime
|
|
35
35
|
prerelease: false
|
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
|
37
37
|
requirements:
|
|
38
38
|
- - ~>
|
|
39
39
|
- !ruby/object:Gem::Version
|
|
40
|
-
version: 0.0.
|
|
40
|
+
version: 0.0.13
|
|
41
41
|
- !ruby/object:Gem::Dependency
|
|
42
42
|
name: ice_nine
|
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -150,12 +150,31 @@ dependencies:
|
|
|
150
150
|
- - ~>
|
|
151
151
|
- !ruby/object:Gem::Version
|
|
152
152
|
version: 2.14.1
|
|
153
|
+
- !ruby/object:Gem::Dependency
|
|
154
|
+
name: bundler
|
|
155
|
+
requirement: !ruby/object:Gem::Requirement
|
|
156
|
+
requirements:
|
|
157
|
+
- - ~>
|
|
158
|
+
- !ruby/object:Gem::Version
|
|
159
|
+
version: '1.3'
|
|
160
|
+
- - '>='
|
|
161
|
+
- !ruby/object:Gem::Version
|
|
162
|
+
version: 1.3.5
|
|
163
|
+
type: :development
|
|
164
|
+
prerelease: false
|
|
165
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
166
|
+
requirements:
|
|
167
|
+
- - ~>
|
|
168
|
+
- !ruby/object:Gem::Version
|
|
169
|
+
version: '1.3'
|
|
170
|
+
- - '>='
|
|
171
|
+
- !ruby/object:Gem::Version
|
|
172
|
+
version: 1.3.5
|
|
153
173
|
description: Mutation testing for ruby
|
|
154
174
|
email:
|
|
155
175
|
- mbj@schirp-dso.com
|
|
156
176
|
executables:
|
|
157
177
|
- mutant
|
|
158
|
-
- zombie
|
|
159
178
|
extensions: []
|
|
160
179
|
extra_rdoc_files:
|
|
161
180
|
- TODO
|
|
@@ -163,6 +182,7 @@ extra_rdoc_files:
|
|
|
163
182
|
files:
|
|
164
183
|
- .gitignore
|
|
165
184
|
- .rspec
|
|
185
|
+
- .ruby-gemset
|
|
166
186
|
- .travis.yml
|
|
167
187
|
- Changelog.md
|
|
168
188
|
- Gemfile
|
|
@@ -173,7 +193,6 @@ files:
|
|
|
173
193
|
- Rakefile
|
|
174
194
|
- TODO
|
|
175
195
|
- bin/mutant
|
|
176
|
-
- bin/zombie
|
|
177
196
|
- circle.yml
|
|
178
197
|
- config/devtools.yml
|
|
179
198
|
- config/flay.yml
|
|
@@ -224,7 +243,6 @@ files:
|
|
|
224
243
|
- lib/mutant/mutator/node/begin.rb
|
|
225
244
|
- lib/mutant/mutator/node/block.rb
|
|
226
245
|
- lib/mutant/mutator/node/case.rb
|
|
227
|
-
- lib/mutant/mutator/node/cbase.rb
|
|
228
246
|
- lib/mutant/mutator/node/connective/binary.rb
|
|
229
247
|
- lib/mutant/mutator/node/const.rb
|
|
230
248
|
- lib/mutant/mutator/node/define.rb
|
|
@@ -247,6 +265,7 @@ files:
|
|
|
247
265
|
- lib/mutant/mutator/node/named_value/access.rb
|
|
248
266
|
- lib/mutant/mutator/node/named_value/constant_assignment.rb
|
|
249
267
|
- lib/mutant/mutator/node/named_value/variable_assignment.rb
|
|
268
|
+
- lib/mutant/mutator/node/noop.rb
|
|
250
269
|
- lib/mutant/mutator/node/return.rb
|
|
251
270
|
- lib/mutant/mutator/node/send.rb
|
|
252
271
|
- lib/mutant/mutator/node/send/binary.rb
|
|
@@ -303,6 +322,10 @@ files:
|
|
|
303
322
|
- spec/unit/mutant/cli/class_methods/new_spec.rb
|
|
304
323
|
- spec/unit/mutant/cli/class_methods/run_spec.rb
|
|
305
324
|
- spec/unit/mutant/cli/classifier/class_methods/build_spec.rb
|
|
325
|
+
- spec/unit/mutant/cli/classifier/method/each_spec.rb
|
|
326
|
+
- spec/unit/mutant/cli/classifier/namespace/flat/each_spec.rb
|
|
327
|
+
- spec/unit/mutant/cli/classifier/namespace/recursive/each_spec.rb
|
|
328
|
+
- spec/unit/mutant/cli/classifier/scope/each_spec.rb
|
|
306
329
|
- spec/unit/mutant/context/root_spec.rb
|
|
307
330
|
- spec/unit/mutant/context/scope/root_spec.rb
|
|
308
331
|
- spec/unit/mutant/context/scope/unqualified_name_spec.rb
|
|
@@ -324,13 +347,20 @@ files:
|
|
|
324
347
|
- spec/unit/mutant/mutator/each_spec.rb
|
|
325
348
|
- spec/unit/mutant/mutator/emit_new_spec.rb
|
|
326
349
|
- spec/unit/mutant/mutator/emit_spec.rb
|
|
350
|
+
- spec/unit/mutant/mutator/node/and_asgn/mutation_spec.rb
|
|
327
351
|
- spec/unit/mutant/mutator/node/begin/mutation_spec.rb
|
|
328
352
|
- spec/unit/mutant/mutator/node/block/mutation_spec.rb
|
|
353
|
+
- spec/unit/mutant/mutator/node/block_pass/mutation_spec.rb
|
|
354
|
+
- spec/unit/mutant/mutator/node/break/mutation_spec.rb
|
|
329
355
|
- spec/unit/mutant/mutator/node/case/mutation_spec.rb
|
|
330
356
|
- spec/unit/mutant/mutator/node/cbase/mutation_spec.rb
|
|
331
357
|
- spec/unit/mutant/mutator/node/connective/binary/mutation_spec.rb
|
|
332
358
|
- spec/unit/mutant/mutator/node/const/mutation_spec.rb
|
|
333
359
|
- spec/unit/mutant/mutator/node/define/mutation_spec.rb
|
|
360
|
+
- spec/unit/mutant/mutator/node/defined_predicate/mutation_spec.rb
|
|
361
|
+
- spec/unit/mutant/mutator/node/dstr/mutation_spec.rb
|
|
362
|
+
- spec/unit/mutant/mutator/node/dsym/mutation_spec.rb
|
|
363
|
+
- spec/unit/mutant/mutator/node/ensure/mutation_spec.rb
|
|
334
364
|
- spec/unit/mutant/mutator/node/if/mutation_spec.rb
|
|
335
365
|
- spec/unit/mutant/mutator/node/literal/array_spec.rb
|
|
336
366
|
- spec/unit/mutant/mutator/node/literal/boolean/mutation_spec.rb
|
|
@@ -343,13 +373,21 @@ files:
|
|
|
343
373
|
- spec/unit/mutant/mutator/node/literal/string_spec.rb
|
|
344
374
|
- spec/unit/mutant/mutator/node/literal/symbol_spec.rb
|
|
345
375
|
- spec/unit/mutant/mutator/node/masgn/mutation_spec.rb
|
|
376
|
+
- spec/unit/mutant/mutator/node/match_current_line/mutation_spec.rb
|
|
346
377
|
- spec/unit/mutant/mutator/node/named_value/access/mutation_spec.rb
|
|
347
378
|
- spec/unit/mutant/mutator/node/named_value/constant_assignment/mutation_spec.rb
|
|
348
379
|
- spec/unit/mutant/mutator/node/named_value/variable_assignment/mutation_spec.rb
|
|
380
|
+
- spec/unit/mutant/mutator/node/next/mutation_spec.rb
|
|
381
|
+
- spec/unit/mutant/mutator/node/op_assgn/mutation_spec.rb
|
|
382
|
+
- spec/unit/mutant/mutator/node/or_asgn/mutation_spec.rb
|
|
383
|
+
- spec/unit/mutant/mutator/node/redo/mutation_spec.rb
|
|
384
|
+
- spec/unit/mutant/mutator/node/rescue/mutation_spec.rb
|
|
385
|
+
- spec/unit/mutant/mutator/node/restarg/mutation_spec.rb
|
|
349
386
|
- spec/unit/mutant/mutator/node/return/mutation_spec.rb
|
|
350
387
|
- spec/unit/mutant/mutator/node/send/mutation_spec.rb
|
|
351
388
|
- spec/unit/mutant/mutator/node/super/mutation_spec.rb
|
|
352
389
|
- spec/unit/mutant/mutator/node/while/mutation_spec.rb
|
|
390
|
+
- spec/unit/mutant/mutator/node/yield/mutation_spec.rb
|
|
353
391
|
- spec/unit/mutant/node_helpers/n_not_spec.rb
|
|
354
392
|
- spec/unit/mutant/runner/config/subjects_spec.rb
|
|
355
393
|
- spec/unit/mutant/runner/config/success_predicate_spec.rb
|
|
@@ -371,7 +409,6 @@ files:
|
|
|
371
409
|
- test_app/spec/shared/invertible_method_behaviour.rb
|
|
372
410
|
- test_app/spec/shared/method_filter_parse_behavior.rb
|
|
373
411
|
- test_app/spec/shared/method_match_behavior.rb
|
|
374
|
-
- test_app/spec/shared/mutator_behavior.rb
|
|
375
412
|
- test_app/spec/spec_helper.rb
|
|
376
413
|
- test_app/spec/unit/test_app/literal/command_spec.rb
|
|
377
414
|
- test_app/spec/unit/test_app/literal/string_spec.rb
|
|
@@ -403,18 +440,14 @@ test_files:
|
|
|
403
440
|
- spec/integration/mutant/rspec_killer_spec.rb
|
|
404
441
|
- spec/integration/mutant/test_mutator_handles_types_spec.rb
|
|
405
442
|
- spec/integration/mutant/zombie_spec.rb
|
|
406
|
-
- spec/rcov.opts
|
|
407
|
-
- spec/shared/method_matcher_behavior.rb
|
|
408
|
-
- spec/shared/mutator_behavior.rb
|
|
409
|
-
- spec/spec_helper.rb
|
|
410
|
-
- spec/support/compress_helper.rb
|
|
411
|
-
- spec/support/ice_nine_config.rb
|
|
412
|
-
- spec/support/rspec.rb
|
|
413
|
-
- spec/support/test_app.rb
|
|
414
443
|
- spec/unit/mutant/class_methods/singleton_subclass_instance_spec.rb
|
|
415
444
|
- spec/unit/mutant/cli/class_methods/new_spec.rb
|
|
416
445
|
- spec/unit/mutant/cli/class_methods/run_spec.rb
|
|
417
446
|
- spec/unit/mutant/cli/classifier/class_methods/build_spec.rb
|
|
447
|
+
- spec/unit/mutant/cli/classifier/method/each_spec.rb
|
|
448
|
+
- spec/unit/mutant/cli/classifier/namespace/flat/each_spec.rb
|
|
449
|
+
- spec/unit/mutant/cli/classifier/namespace/recursive/each_spec.rb
|
|
450
|
+
- spec/unit/mutant/cli/classifier/scope/each_spec.rb
|
|
418
451
|
- spec/unit/mutant/context/root_spec.rb
|
|
419
452
|
- spec/unit/mutant/context/scope/root_spec.rb
|
|
420
453
|
- spec/unit/mutant/context/scope/unqualified_name_spec.rb
|
|
@@ -436,13 +469,20 @@ test_files:
|
|
|
436
469
|
- spec/unit/mutant/mutator/each_spec.rb
|
|
437
470
|
- spec/unit/mutant/mutator/emit_new_spec.rb
|
|
438
471
|
- spec/unit/mutant/mutator/emit_spec.rb
|
|
472
|
+
- spec/unit/mutant/mutator/node/and_asgn/mutation_spec.rb
|
|
439
473
|
- spec/unit/mutant/mutator/node/begin/mutation_spec.rb
|
|
440
474
|
- spec/unit/mutant/mutator/node/block/mutation_spec.rb
|
|
475
|
+
- spec/unit/mutant/mutator/node/block_pass/mutation_spec.rb
|
|
476
|
+
- spec/unit/mutant/mutator/node/break/mutation_spec.rb
|
|
441
477
|
- spec/unit/mutant/mutator/node/case/mutation_spec.rb
|
|
442
478
|
- spec/unit/mutant/mutator/node/cbase/mutation_spec.rb
|
|
443
479
|
- spec/unit/mutant/mutator/node/connective/binary/mutation_spec.rb
|
|
444
480
|
- spec/unit/mutant/mutator/node/const/mutation_spec.rb
|
|
445
481
|
- spec/unit/mutant/mutator/node/define/mutation_spec.rb
|
|
482
|
+
- spec/unit/mutant/mutator/node/defined_predicate/mutation_spec.rb
|
|
483
|
+
- spec/unit/mutant/mutator/node/dstr/mutation_spec.rb
|
|
484
|
+
- spec/unit/mutant/mutator/node/dsym/mutation_spec.rb
|
|
485
|
+
- spec/unit/mutant/mutator/node/ensure/mutation_spec.rb
|
|
446
486
|
- spec/unit/mutant/mutator/node/if/mutation_spec.rb
|
|
447
487
|
- spec/unit/mutant/mutator/node/literal/array_spec.rb
|
|
448
488
|
- spec/unit/mutant/mutator/node/literal/boolean/mutation_spec.rb
|
|
@@ -455,13 +495,21 @@ test_files:
|
|
|
455
495
|
- spec/unit/mutant/mutator/node/literal/string_spec.rb
|
|
456
496
|
- spec/unit/mutant/mutator/node/literal/symbol_spec.rb
|
|
457
497
|
- spec/unit/mutant/mutator/node/masgn/mutation_spec.rb
|
|
498
|
+
- spec/unit/mutant/mutator/node/match_current_line/mutation_spec.rb
|
|
458
499
|
- spec/unit/mutant/mutator/node/named_value/access/mutation_spec.rb
|
|
459
500
|
- spec/unit/mutant/mutator/node/named_value/constant_assignment/mutation_spec.rb
|
|
460
501
|
- spec/unit/mutant/mutator/node/named_value/variable_assignment/mutation_spec.rb
|
|
502
|
+
- spec/unit/mutant/mutator/node/next/mutation_spec.rb
|
|
503
|
+
- spec/unit/mutant/mutator/node/op_assgn/mutation_spec.rb
|
|
504
|
+
- spec/unit/mutant/mutator/node/or_asgn/mutation_spec.rb
|
|
505
|
+
- spec/unit/mutant/mutator/node/redo/mutation_spec.rb
|
|
506
|
+
- spec/unit/mutant/mutator/node/rescue/mutation_spec.rb
|
|
507
|
+
- spec/unit/mutant/mutator/node/restarg/mutation_spec.rb
|
|
461
508
|
- spec/unit/mutant/mutator/node/return/mutation_spec.rb
|
|
462
509
|
- spec/unit/mutant/mutator/node/send/mutation_spec.rb
|
|
463
510
|
- spec/unit/mutant/mutator/node/super/mutation_spec.rb
|
|
464
511
|
- spec/unit/mutant/mutator/node/while/mutation_spec.rb
|
|
512
|
+
- spec/unit/mutant/mutator/node/yield/mutation_spec.rb
|
|
465
513
|
- spec/unit/mutant/node_helpers/n_not_spec.rb
|
|
466
514
|
- spec/unit/mutant/runner/config/subjects_spec.rb
|
|
467
515
|
- spec/unit/mutant/runner/config/success_predicate_spec.rb
|
data/bin/zombie
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env ruby
|
|
2
|
-
|
|
3
|
-
trap('INT') do |status|
|
|
4
|
-
exit! 128+status
|
|
5
|
-
end
|
|
6
|
-
|
|
7
|
-
require 'mutant'
|
|
8
|
-
|
|
9
|
-
namespace =
|
|
10
|
-
if File.basename($0) == 'zombie'
|
|
11
|
-
$stderr.puts('Detected zombie environment...')
|
|
12
|
-
Mutant::Zombifier.zombify
|
|
13
|
-
Zombie::Mutant
|
|
14
|
-
else
|
|
15
|
-
Mutant
|
|
16
|
-
end
|
|
17
|
-
|
|
18
|
-
Kernel.exit(namespace::CLI.run(ARGV))
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
shared_examples_for 'a mutator' do
|
|
2
|
-
subject { object.each(node) { |item| yields << item } }
|
|
3
|
-
|
|
4
|
-
let(:yields) { [] }
|
|
5
|
-
let(:object) { described_class }
|
|
6
|
-
|
|
7
|
-
unless instance_methods.map(&:to_s).include?('node')
|
|
8
|
-
let(:node) { source.to_ast }
|
|
9
|
-
end
|
|
10
|
-
|
|
11
|
-
it_should_behave_like 'a command method'
|
|
12
|
-
|
|
13
|
-
context 'with no block' do
|
|
14
|
-
subject { object.each(node) }
|
|
15
|
-
|
|
16
|
-
it { should be_instance_of(to_enum.class) }
|
|
17
|
-
|
|
18
|
-
let(:expected_mutations) do
|
|
19
|
-
mutations.map do |mutation|
|
|
20
|
-
if mutation.respond_to?(:to_ast)
|
|
21
|
-
mutation.to_ast.to_sexp
|
|
22
|
-
else
|
|
23
|
-
mutation
|
|
24
|
-
end
|
|
25
|
-
end.to_set
|
|
26
|
-
end
|
|
27
|
-
|
|
28
|
-
it 'generates the expected mutations' do
|
|
29
|
-
subject = self.subject.map(&:to_sexp).to_set
|
|
30
|
-
|
|
31
|
-
unless subject == expected_mutations
|
|
32
|
-
message = "Missing mutations: %s\nUnexpected mutations: %s" %
|
|
33
|
-
[expected_mutations - subject, subject - expected_mutations ].map(&:to_a).map(&:inspect)
|
|
34
|
-
fail message
|
|
35
|
-
end
|
|
36
|
-
end
|
|
37
|
-
end
|
|
38
|
-
end
|
|
39
|
-
|
|
40
|
-
shared_examples_for 'a noop mutator' do
|
|
41
|
-
let(:mutations) { [] }
|
|
42
|
-
|
|
43
|
-
it_should_behave_like 'a mutator'
|
|
44
|
-
end
|