Class: Mutant::Subject::Config Private
- Inherits:
-
Object
- Object
- Mutant::Subject::Config
- Includes:
- Unparser::Adamantium
- Defined in:
- lib/mutant/subject/config.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Constant Summary collapse
- DEFAULT =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
new(inline_disable: false, mutation: Mutation::Config::DEFAULT)
- DISABLE_REGEXP =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
/(\s|^)mutant:disable(?:\s|$)/
- SYNTAX_REGEXP =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
/\A(?:#|=begin\n)/
Class Method Summary collapse
Class Method Details
.parse(comments:, mutation:) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
13 14 15 16 17 18 |
# File 'lib/mutant/subject/config.rb', line 13 def self.parse(comments:, mutation:) new( inline_disable: comments.any? { |comment| DISABLE_REGEXP.match?(comment_body(comment)) }, mutation: ) end |