mutant
mutant copied to clipboard
Shared meta examples
#413 required adding the same example 9 times to meta/def.rb: diff.
It would be nice if we could specify something like subset in the example below:
Mutant::Meta::Example.add do
source 'def foo; end'
mutation 'def foo; raise; end'
end
Mutant::Meta::Example.add do
source 'def foo; foo; rescue; end'
subset 'def foo; end'
mutation 'def foo; nil; rescue; end'
mutation 'def foo; self; rescue; end'
mutation 'def foo; end'
mutation 'def foo; foo; end'
end
where subset indicates that the mutations from the first example should also show up in the second example.