Subhanshu20135 commented on code in PR #7283:
URL: https://github.com/apache/incubator-kie/pull/7283#discussion_r4565844436


##########
kie-archetypes/kie-drools-exec-model-ruleunit-archetype/src/test/resources/projects/integrationtestDefaults/reference/src/test/java/it/pkg/RuleTest.java:
##########
@@ -23,13 +23,13 @@
 
 import org.drools.ruleunits.api.RuleUnitProvider;
 import org.drools.ruleunits.api.RuleUnitInstance;
-import org.junit.Test;
+import org.junit.jupiter.api.Test;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 import static java.util.stream.Collectors.toList;
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
+import static org.junit.jupiter.api.Assertions.assertEquals;

Review Comment:
   Ok, I will migrate the JUnit Assertions to AssertJ.



##########
drools-compiler/pom.xml:
##########
@@ -236,12 +236,9 @@
             <groupId>org.apache.maven.plugins</groupId>
             <artifactId>maven-surefire-plugin</artifactId>
             <configuration>
-              <properties>
-                <property>
-                  <name>listener</name>
-                  <value>org.kie.test.util.TestStatusListener</value>
-                </property>
-              </properties>
+              <additionalClasspathElements>

Review Comment:
   Hi @gitgabrio,
   
   The Change is the official Java SPI (Service Provider Interface) mechanism. 
The new SPI-based approach ensures the listener is discovered reliably every 
time the profile is activated. Also it cleanly scoped the change *only* to 
Surefire's test classpath. 
   
   By pointing `${project.basedir}/src/test/enable-test-status-listener` as an 
additional classpath element, the `META-INF/services` descriptor is found 
precisely when that specific Maven profile (`-DenableTestStatusListener`) is 
turned on — nothing leaks into other builds or profiles.
   
   
   
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to