lib/mutant/matcher/config.rb in mutant-0.9.8 vs lib/mutant/matcher/config.rb in mutant-0.9.9
- old
+ new
@@ -42,32 +42,21 @@
with(attribute => public_send(attribute) + [value])
end
private
- # Present attributes
- #
- # @return [Array<Symbol>]
def present_attributes
to_h.reject { |_key, value| value.empty? }.keys
end
- # Formatted attributes
- #
- # @return [String]
def inspect_attributes
attributes = present_attributes
.map(&method(:format_attribute))
.join(ATTRIBUTE_DELIMITER)
attributes.empty? ? EMPTY_ATTRIBUTES : attributes
end
- # Format attribute
- #
- # @param [Symbol] attribute_name
- #
- # @return [String]
def format_attribute(attribute_name)
ATTRIBUTE_FORMAT %
[
attribute_name,
public_send(attribute_name)