CI: Add SonarCloud scan GHA workflow
[nonrtric/plt/ranpm.git] / pmproducer / src / test / java / org / oran / pmproducer / IntegrationWithKafka.java
index 990e7b2..27d3170 100644 (file)
@@ -86,10 +86,14 @@ import reactor.kafka.sender.SenderRecord;
         "app.configuration-filepath=./src/test/resources/test_application_configuration.json", //
         "app.pm-files-path=./src/test/resources/", //
         "app.s3.locksBucket=ropfilelocks", //
-        "app.pm-files-path=/tmp/dmaapadaptor", //
-        "app.s3.bucket=dmaaptest", //
+        "app.pm-files-path=/tmp/pmproducer", //
+        "app.s3.bucket=pmproducertest", //
         "app.auth-token-file=src/test/resources/jwtToken.b64", //
         "app.kafka.use-oath-token=false"}) //
+/**
+ * Tests interwork with Kafka and Minio
+ * Requires that Kafka and ICS is started.
+ */
 class IntegrationWithKafka {
 
     final static String PM_TYPE_ID = "PmDataOverKafka";
@@ -455,8 +459,9 @@ class IntegrationWithKafka {
         }
 
         String msgString = kafkaReceiver.receivedKafkaOutput.valueAsString();
-        assertThat(msgString).contains("pmCounterNumber0");
-        assertThat(msgString).doesNotContain("pmCounterNumber1");
+        assertThat(msgString)
+            .contains("pmCounterNumber0")
+            .doesNotContain("pmCounterNumber1");
         assertThat(kafkaReceiver.receivedKafkaOutput.getTypeIdFromHeaders()).isEqualTo(PM_TYPE_ID);
         assertThat(kafkaReceiver.receivedKafkaOutput.getSourceNameFromHeaders()).isEqualTo("HTTPST2-0"); // This is from
                                                                                                          // the file
@@ -615,7 +620,7 @@ class IntegrationWithKafka {
 
     @Test
     void testHistoricalData() throws Exception {
-        // test
+        // test that it works to get already fetched data
         final String JOB_ID = "testHistoricalData";
 
         DataStore fileStore = dataStore();