From 3cb1e0eee40c73b58146463ed1abb35e673c241c Mon Sep 17 00:00:00 2001 From: Hakanai Date: Fri, 10 Feb 2023 10:04:40 +1100 Subject: [PATCH] Replace result.class with result.klass `result.class` returns the class of the result object, but what you really want is the name of the test class, which is in `result.klass`. --- lib/ci/reporter/minitest.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/ci/reporter/minitest.rb b/lib/ci/reporter/minitest.rb index a03e61a..a139a67 100644 --- a/lib/ci/reporter/minitest.rb +++ b/lib/ci/reporter/minitest.rb @@ -77,13 +77,13 @@ def record(result) # suite we are in, and is only called at the granularity of a # test. We have to work backwards to understand when the suite # changes. - if @current_suite_class != result.class + if @current_suite_class != result.klass finish_suite start_suite end - @current_suite_class = result.class - @current_suite.name = result.class.to_s + @current_suite_class = result.klass + @current_suite.name = result.klass.to_s tc = TestCase.new(result.name, result.time, result.assertions) tc.failures = result.failures.map {|f| Failure.classify(f)}