Skip to content

Commit

Permalink
WFLY-18080 Fix FaultToleranceMicrometerIntegrationTestCase to check f…
Browse files Browse the repository at this point in the history
…or Docker being available which is a requirement of the MicrometerSetupTask.
  • Loading branch information
rhusar committed Feb 8, 2024
1 parent e659e44 commit 3d4a347
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,12 @@
import org.jboss.as.arquillian.api.ServerSetup;
import org.jboss.as.arquillian.api.ServerSetupTask;
import org.jboss.as.test.integration.common.HttpRequest;
import org.jboss.as.test.shared.util.AssumeTestGroupUtil;
import org.jboss.shrinkwrap.api.Archive;
import org.jboss.shrinkwrap.api.ShrinkWrap;
import org.jboss.shrinkwrap.api.spec.WebArchive;
import org.junit.Assert;
import org.junit.BeforeClass;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.wildfly.test.integration.microprofile.faulttolerance.micrometer.deployment.FaultTolerantApplication;
Expand Down Expand Up @@ -65,6 +67,14 @@ public static Archive<?> deploy() {
@Inject
private MeterRegistry meterRegistry;

// The @ServerSetup(MicrometerSetupTask.class) requires Docker to be available.
// Otherwise the org.wildfly.extension.micrometer.registry.NoOpRegistry is installed which will result in 0 counters,
// and cause the test fail seemingly intermittently on machines with broken Docker setup.
@BeforeClass
public static void checkForDocker() {
AssumeTestGroupUtil.assumeDockerAvailable();
}

@Test
@InSequence(1)
public void clearInjectedRegistry() {
Expand Down

0 comments on commit 3d4a347

Please sign in to comment.