-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
185 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
...test/java/io/quarkiverse/temporal/deployment/QuarkusManagedChannelConfigPriorityTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
package io.quarkiverse.temporal.deployment; | ||
|
||
import jakarta.inject.Inject; | ||
|
||
import org.jboss.shrinkwrap.api.ShrinkWrap; | ||
import org.jboss.shrinkwrap.api.asset.StringAsset; | ||
import org.jboss.shrinkwrap.api.spec.JavaArchive; | ||
import org.junit.jupiter.api.Assertions; | ||
import org.junit.jupiter.api.Test; | ||
import org.junit.jupiter.api.extension.RegisterExtension; | ||
|
||
import io.quarkus.test.QuarkusUnitTest; | ||
import io.temporal.serviceclient.WorkflowServiceStubs; | ||
|
||
public class QuarkusManagedChannelConfigPriorityTest { | ||
|
||
@RegisterExtension | ||
static final QuarkusUnitTest unitTest = new QuarkusUnitTest() | ||
.setArchiveProducer(() -> ShrinkWrap.create(JavaArchive.class) | ||
.addAsResource( | ||
new StringAsset( | ||
"quarkus.temporal.start-workers: false\n" + | ||
"quarkus.temporal.channel-type: quarkus-managed\n" + | ||
"quarkus.grpc.clients.temporal-client.host: grpcHost\n" + | ||
"quarkus.temporal.connection.target: customTarget:1234\n"), | ||
"application.properties")); | ||
|
||
@Inject | ||
WorkflowServiceStubs serviceStubs; | ||
|
||
@Test | ||
public void testQuarkusManagedChannel() { | ||
Assertions.assertNull(serviceStubs.getOptions().getTarget()); | ||
Assertions.assertEquals("grpcHost:1234", serviceStubs.getOptions().getChannel().authority()); | ||
} | ||
} |
35 changes: 35 additions & 0 deletions
35
...eployment/src/test/java/io/quarkiverse/temporal/deployment/QuarkusManagedChannelTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
package io.quarkiverse.temporal.deployment; | ||
|
||
import jakarta.inject.Inject; | ||
|
||
import org.jboss.shrinkwrap.api.ShrinkWrap; | ||
import org.jboss.shrinkwrap.api.asset.StringAsset; | ||
import org.jboss.shrinkwrap.api.spec.JavaArchive; | ||
import org.junit.jupiter.api.Assertions; | ||
import org.junit.jupiter.api.Test; | ||
import org.junit.jupiter.api.extension.RegisterExtension; | ||
|
||
import io.quarkus.test.QuarkusUnitTest; | ||
import io.temporal.serviceclient.WorkflowServiceStubs; | ||
|
||
public class QuarkusManagedChannelTest { | ||
|
||
@RegisterExtension | ||
static final QuarkusUnitTest unitTest = new QuarkusUnitTest() | ||
.setArchiveProducer(() -> ShrinkWrap.create(JavaArchive.class) | ||
.addAsResource( | ||
new StringAsset( | ||
"quarkus.temporal.start-workers: false\n" + | ||
"quarkus.temporal.channel-type: quarkus-managed\n" + | ||
"quarkus.temporal.connection.target: customTarget:1234\n"), | ||
"application.properties")); | ||
|
||
@Inject | ||
WorkflowServiceStubs serviceStubs; | ||
|
||
@Test | ||
public void testQuarkusManagedChannel() { | ||
Assertions.assertNull(serviceStubs.getOptions().getTarget()); | ||
Assertions.assertEquals("customTarget:1234", serviceStubs.getOptions().getChannel().authority()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters