Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
vietj committed Feb 28, 2024
1 parent 0844f65 commit 54335c7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -686,14 +686,14 @@
</configuration>
</execution>
<execution>
<id>custom-context-key</id>
<id>custom-context-local</id>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<includes>
<include>io/vertx/it/CustomContextKeyTest.java</include>
<include>io/vertx/it/CustomContextLocalTest.java</include>
</includes>
<additionalClasspathElements>
<additionalClasspathElement>${project.basedir}/src/test/classpath/customcontextkey</additionalClasspathElement>
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
io.vertx.it.CustomContextKey
io.vertx.it.CustomContextLocal
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import io.vertx.core.spi.VertxServiceProvider;
import io.vertx.core.spi.context.storage.ContextLocal;

public class CustomContextKey implements VertxServiceProvider {
public class CustomContextLocal implements VertxServiceProvider {

public static ContextLocal<Object> CUSTOM_KEY = ContextLocal.registerLocal(Object.class);
public static volatile boolean initialized;
Expand Down
6 changes: 3 additions & 3 deletions src/test/java/io/vertx/it/CustomContextLocalTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ public class CustomContextLocalTest extends VertxTestBase {

@Test
public void testResolver() {
assertTrue(CustomContextKey.initialized);
assertTrue(CustomContextLocal.initialized);
Context context = vertx.getOrCreateContext();
Object o = new Object();
context.putLocal(CustomContextKey.CUSTOM_KEY, o);
assertSame(o, context.getLocal(CustomContextKey.CUSTOM_KEY));
context.putLocal(CustomContextLocal.CUSTOM_KEY, o);
assertSame(o, context.getLocal(CustomContextLocal.CUSTOM_KEY));
}
}

0 comments on commit 54335c7

Please sign in to comment.