lib/rubocop/cop/mixin/minitest_exploration_helpers.rb in rubocop-minitest-0.27.0 vs lib/rubocop/cop/mixin/minitest_exploration_helpers.rb in rubocop-minitest-0.28.0
- old
+ new
@@ -10,17 +10,19 @@
include DefNode
extend NodePattern::Macros
ASSERTION_PREFIXES = %w[assert refute].freeze
- LIFECYCLE_HOOK_METHODS = %i[
+ LIFECYCLE_HOOK_METHODS_IN_ORDER = %i[
before_setup
setup
after_setup
before_teardown
teardown
after_teardown
- ].to_set.freeze
+ ].freeze
+
+ LIFECYCLE_HOOK_METHODS = LIFECYCLE_HOOK_METHODS_IN_ORDER.to_set.freeze
private
def test_class?(class_node)
class_node.parent_class && class_node.identifier.source.end_with?('Test')