Skip to content

Commit

Permalink
[312] Skip the Context and InitialContext parameter injection for Pay…
Browse files Browse the repository at this point in the history
…ara. There is an issue with where/when the InitialContext producer is initialized for JUnit 5 ParameterResolvers.

Signed-off-by: James R. Perkins <[email protected]>
  • Loading branch information
jamezp committed Aug 12, 2024
1 parent 7f37411 commit 7a3a271
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
import org.jboss.arquillian.test.api.ArquillianResource;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
import org.junit.jupiter.api.io.TempDir;

/**
Expand All @@ -49,6 +50,7 @@ public void checkContext() throws Exception {
}

@Test
@DisabledIfSystemProperty(named = "javax.naming.Context.parameter", matches = "skip")
public void checkContextParameter(@ArquillianResource final Context context) throws Exception {
Assertions.assertNotNull(context, "The Context should have been injected");
final Object bm = context.lookup("java:comp/BeanManager");
Expand All @@ -63,6 +65,7 @@ public void checkInitialContext() throws Exception {
}

@Test
@DisabledIfSystemProperty(named = "javax.naming.Context.parameter", matches = "skip")
public void checkInitialContextParameter(@ArquillianResource final InitialContext initialContext) throws Exception {
Assertions.assertNotNull(initialContext, "The InitialContext should have been injected");
final Object bm = initialContext.lookup("java:comp/BeanManager");
Expand Down
2 changes: 2 additions & 0 deletions integration-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@
<groupId>fish.payara.arquillian</groupId>
<artifactId>arquillian-payara-server-managed</artifactId>
<version>${version.fish.payara.arquillian}</version>
<scope>test</scope>
</dependency>
</dependencies>

Expand Down Expand Up @@ -292,6 +293,7 @@
<systemPropertyVariables>
<payara.home>${payara.home}</payara.home>
<arq.host>localhost</arq.host>
<javax.naming.Context.parameter>skip</javax.naming.Context.parameter>
</systemPropertyVariables>
</configuration>
</plugin>
Expand Down

0 comments on commit 7a3a271

Please sign in to comment.