ChrisSamo632 commented on code in PR #6806: URL: https://github.com/apache/nifi/pull/6806#discussion_r1059057282
########## nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-site-to-site/src/test/groovy/org/apache/nifi/remote/StandardPublicPortGroovyTest.groovy: ########## @@ -24,51 +24,38 @@ import org.apache.nifi.remote.protocol.CommunicationsSession import org.apache.nifi.remote.protocol.ServerProtocol import org.apache.nifi.reporting.BulletinRepository import org.apache.nifi.util.NiFiProperties -import org.junit.After -import org.junit.Before -import org.junit.BeforeClass -import org.junit.Ignore -import org.junit.Test -import org.junit.runner.RunWith -import org.junit.runners.JUnit4 +import org.junit.jupiter.api.Disabled +import org.junit.jupiter.api.Test +import org.junit.jupiter.api.BeforeAll import org.slf4j.Logger import org.slf4j.LoggerFactory -@RunWith(JUnit4.class) -class StandardPublicPortGroovyTest extends GroovyTestCase { +class StandardPublicPortGroovyTest { private static final Logger logger = LoggerFactory.getLogger(StandardPublicPortGroovyTest.class) - @BeforeClass + @BeforeAll static void setUpOnce() throws Exception { logger.metaClass.methodMissing = { String name, args -> logger.info("[${name?.toUpperCase()}] ${(args as List).join(" ")}") } } - @Before - void setUp() { - - } - - @After - void tearDown() { - - } - private static PublicPort createPublicPort(NiFiProperties niFiProperties) { Authorizer mockAuthorizer = [:] as Authorizer BulletinRepository mockBulletinRepository = [:] as BulletinRepository ProcessScheduler mockProcessScheduler = [registerEvent: { Connectable worker -> logger.mock("Registered event for worker: ${worker}") }] as ProcessScheduler - StandardPublicPort spp = new StandardPublicPort("id", "name", TransferDirection.RECEIVE, ConnectableType.INPUT_PORT, mockAuthorizer, mockBulletinRepository, mockProcessScheduler, false, niFiProperties.getBoredYieldDuration(), []) + StandardPublicPort spp = + new StandardPublicPort("id", "name", TransferDirection.RECEIVE, ConnectableType.INPUT_PORT, + mockAuthorizer, mockBulletinRepository, mockProcessScheduler, false, niFiProperties.getBoredYieldDuration(), []) logger.info("Created SPP with mocked collaborators: ${spp}") spp } // TODO: Implement test - @Ignore("Not yet implemented") + @Disabled("Not yet implemented") Review Comment: I guess leaving it `Disabled` for now makes sense then and hope it is fixed in the future, but if the `Test` method is being retained now then replacing the raw `assert` would at least seem worthwhile -- 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: issues-unsubscr...@nifi.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org