mutant 0.7.4 → 0.7.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +3 -2
- data/Changelog.md +6 -2
- data/Gemfile +1 -0
- data/config/flay.yml +1 -1
- data/config/reek.yml +1 -1
- data/lib/mutant.rb +4 -3
- data/lib/mutant/cli.rb +2 -2
- data/lib/mutant/config.rb +2 -3
- data/lib/mutant/env.rb +29 -132
- data/lib/mutant/env/bootstrap.rb +155 -0
- data/lib/mutant/expression.rb +27 -0
- data/lib/mutant/expression/namespace.rb +2 -2
- data/lib/mutant/matcher/method.rb +1 -1
- data/lib/mutant/matcher/method/instance.rb +1 -1
- data/lib/mutant/mutation.rb +2 -30
- data/lib/mutant/mutator/node/begin.rb +1 -3
- data/lib/mutant/mutator/node/if.rb +2 -2
- data/lib/mutant/reporter/cli/printer.rb +5 -4
- data/lib/mutant/result.rb +1 -1
- data/lib/mutant/runner.rb +3 -3
- data/lib/mutant/runner/sink.rb +86 -53
- data/lib/mutant/selector.rb +17 -0
- data/lib/mutant/selector/expression.rb +28 -0
- data/lib/mutant/subject.rb +1 -19
- data/lib/mutant/version.rb +1 -1
- data/mutant.gemspec +3 -3
- data/spec/spec_helper.rb +1 -1
- data/spec/support/corpus.rb +5 -5
- data/spec/support/shared_context.rb +1 -6
- data/spec/unit/mutant/cli_spec.rb +2 -2
- data/spec/unit/mutant/env/boostrap_spec.rb +130 -0
- data/spec/unit/mutant/env_spec.rb +61 -49
- data/spec/unit/mutant/expression_spec.rb +13 -0
- data/spec/unit/mutant/matcher/filter_spec.rb +1 -1
- data/spec/unit/mutant/matcher/method/instance_spec.rb +1 -1
- data/spec/unit/mutant/matcher/method/singleton_spec.rb +1 -1
- data/spec/unit/mutant/mutation_spec.rb +0 -36
- data/spec/unit/mutant/reporter/trace_spec.rb +1 -1
- data/spec/unit/mutant/require_highjack_spec.rb +2 -4
- data/spec/unit/mutant/result/subject_spec.rb +2 -1
- data/spec/unit/mutant/runner/{sink_spec.rb → sink/mutation_spec.rb} +1 -3
- data/spec/unit/mutant/runner_spec.rb +4 -3
- data/spec/unit/mutant/selector/expression_spec.rb +60 -0
- data/spec/unit/mutant/subject/method/instance_spec.rb +3 -5
- data/spec/unit/mutant/subject/method/singleton_spec.rb +2 -3
- data/spec/unit/mutant/subject_spec.rb +1 -53
- data/spec/unit/mutant/warning_filter_spec.rb +2 -4
- metadata +18 -15
- data/lib/mutant/line_trace.rb +0 -34
- data/spec/unit/mutant/line_trace_spec.rb +0 -38
- data/spec/unit/mutant/subject/context_spec.rb +0 -16
@@ -1,16 +0,0 @@
|
|
1
|
-
RSpec.describe Mutant::Subject, '#context' do
|
2
|
-
subject { object.context }
|
3
|
-
|
4
|
-
let(:class_under_test) do
|
5
|
-
Class.new(described_class)
|
6
|
-
end
|
7
|
-
|
8
|
-
let(:object) { class_under_test.new(config, context, node) }
|
9
|
-
let(:config) { Mutant::Config::DEFAULT }
|
10
|
-
let(:node) { double('Node') }
|
11
|
-
let(:context) { double('Context') }
|
12
|
-
|
13
|
-
it { should be(context) }
|
14
|
-
|
15
|
-
it_should_behave_like 'an idempotent method'
|
16
|
-
end
|