free_mutant/meta/match_current_line.rb
Markus Schirp 7bf70d9634 Add support for explicit type in meta examples
* This is needed to relate examples to node types for nodes that cannot
  stand alone. Example are :where nodes that do not have syntax outside
  a :case
2016-03-19 15:13:05 +00:00

13 lines
302 B
Ruby

Mutant::Meta::Example.add :match_current_line do
source 'true if /foo/'
singleton_mutations
mutation 'false if /foo/'
mutation 'true if //'
mutation 'nil if /foo/'
mutation 'true if true'
mutation 'true if false'
mutation 'true if nil'
mutation 'true if /a\A/'
mutation 'true'
end