diff --git a/tests/pom.xml b/tests/pom.xml index f401309..b2a6669 100644 --- a/tests/pom.xml +++ b/tests/pom.xml @@ -72,7 +72,25 @@ true - + + + org.apache.maven.plugins + maven-dependency-plugin + 3.9.0 + + + install + + copy-dependencies + + + + ${project.build.directory}/lib + runtime + + + + maven-compiler-plugin 3.13.0 diff --git a/tests/src/test/java/cz/moneta/test/system/messaging/ImqFirstVisionTest.java b/tests/src/test/java/cz/moneta/test/system/messaging/ImqFirstVisionTest.java new file mode 100644 index 0000000..6ed8835 --- /dev/null +++ b/tests/src/test/java/cz/moneta/test/system/messaging/ImqFirstVisionTest.java @@ -0,0 +1,21 @@ +package cz.moneta.test.system.messaging; + +import cz.moneta.test.dsl.Harness; +import cz.moneta.test.harness.annotations.TestCase; +import cz.moneta.test.harness.annotations.TestScenario; +import cz.moneta.test.harness.endpoints.imq.ImqFirstVisionQueue; + +/** + * Unit tests for IBM MQ First Vision DSL methods. + */ +@TestScenario(name = "Send MQ message") +public class ImqFirstVisionTest { + + @TestCase(name = "Send JSON message") + public void sendJsonMessage(Harness harness) { + harness.withImqFirstVision() + .toQueue(ImqFirstVisionQueue.PAYMENT_NOTIFICATIONS) + .withPayload("{\"paymentId\": \"PAY-456\", \"result\": \"OK\"}") + .send(); + } +} diff --git a/tests/src/test/resources/envs/mq b/tests/src/test/resources/envs/mq new file mode 100644 index 0000000..7f6ed5e --- /dev/null +++ b/tests/src/test/resources/envs/mq @@ -0,0 +1,27 @@ +environment.type=TST1 + +browser=chrome + +#IBM MQ First Vision +endpoints.imq-first-vision.connection-name-list=localhost(1414) +endpoints.imq-first-vision.channel=DEV.APP.SVRCONN +endpoints.imq-first-vision.queue-manager=QM1 +endpoints.imq-first-vision.ssl-cipher-suite=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 +endpoints.imq-first-vision.keystore.path=/home/kamma/aa/mq-docker/truststore.jks +endpoints.imq-first-vision.keystore.password=changeit + +#IBM MQ queues +endpoints.imq-first-vision.payment-notifications.queue=DEV.QUEUE.1 +endpoints.imq-first-vision.payment-request.queue=XML.QUEUE.1 +endpoints.imq-first-vision.mf-requests.queue=XML.QUEUE.1 +endpoints.imq-first-vision.mf-responses.queue=XML.QUEUE.1 +endpoints.imq-first-vision.mf-ebcdic.queue=EBCDIC.QUEUE.1 +endpoints.imq-first-vision.mf-utf8.queue=UTF8.QUEUE.1 + + +vault.url=http://localhost:8200 +vault.username=app +vault.password=app + +#Vault path for IBM MQ credentials +vault.imq-first-vision.secrets.path=/kv/autotesty/tst1/imq-first-vision \ No newline at end of file diff --git a/tests/src/test/resources/envs/tst1 b/tests/src/test/resources/envs/tst1 index c8d351f..8d5676e 100644 --- a/tests/src/test/resources/envs/tst1 +++ b/tests/src/test/resources/envs/tst1 @@ -98,20 +98,3 @@ endpoints.exevido.url=https://exevido.tst.moneta-containers.net/#/auth/login #Cashman endpoints.cashman.url=https://cashmantst.mbid.cz/ - -#IBM MQ First Vision -endpoints.imq-first-vision.connection-name-list=mq9multitst5x(1414),mq9multitst6x(1414) -endpoints.imq-first-vision.channel=CLIENT.CHANNEL -endpoints.imq-first-vision.queue-manager=MVSW2TST3 -endpoints.imq-first-vision.ssl-cipher-suite=TLS_RSA_WITH_AES_256_CBC_SHA256 - -#IBM MQ queues -endpoints.imq-first-vision.payment-notifications.queue=MVSW2TST3.DELIVERY.NOTIFICATION -endpoints.imq-first-vision.payment-request.queue=MVSW2TST3.DELIVERY.REQUEST -endpoints.imq-first-vision.mf-requests.queue=MVSW2TST3.MF.REQUESTS -endpoints.imq-first-vision.mf-responses.queue=MVSW2TST3.MF.RESPONSES -endpoints.imq-first-vision.mf-ebcdic.queue=MVSW2TST3.MF.EBCDIC -endpoints.imq-first-vision.mf-utf8.queue=MVSW2TST3.MF.UTF8 - -#Vault path for IBM MQ credentials -vault.imq-first-vision.secrets.path=/kv/autotesty/tst1/imq-first-vision \ No newline at end of file