Compare commits

..

3 Commits

Author SHA1 Message Date
Radek Davidek
579246d772 Merge branch 'main' of https://gitea.kamma.cz/kamma/harness.git into main 2026-03-17 15:08:14 +01:00
Radek Davidek
e6dd8c286b first test 2026-03-17 15:08:05 +01:00
Radek Davidek
ae4bb84eef for test purposes removed vault 2026-03-17 15:07:47 +01:00
5 changed files with 72 additions and 21 deletions

View File

@ -48,7 +48,7 @@ public class ImqFirstVisionEndpoint implements Endpoint {
// Load credentials from Vault
String vaultPath = getVaultPath();
Credentials credentials = loadCredentialsFromVault(vaultPath);
//Credentials credentials = loadCredentialsFromVault(vaultPath);
// SSL configuration (optional)
String keystorePath = null;
@ -59,8 +59,10 @@ public class ImqFirstVisionEndpoint implements Endpoint {
connectionNameList,
channel,
queueManager,
credentials.getUsername(),
credentials.getPassword(),
//credentials.getUsername(),
//credentials.getPassword(),
"app",
"app",
keystorePath,
keystorePassword,
sslCipherSuite

View File

@ -72,7 +72,25 @@
<activeByDefault>true</activeByDefault>
</activation>
<build>
<plugins>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.9.0</version>
<executions>
<execution>
<phase>install</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>
${project.build.directory}/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.13.0</version>

View File

@ -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();
}
}

View File

@ -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

View File

@ -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