diff --git a/streampipes-extensions/streampipes-processors-enricher-jvm/src/test/java/org/apache/streampipes/processors/enricher/jvm/processor/math/MathOpProcessorTest.java b/streampipes-extensions/streampipes-processors-enricher-jvm/src/test/java/org/apache/streampipes/processors/enricher/jvm/processor/math/MathOpProcessorTest.java index 04b41d3f52..ca154f3b8b 100644 --- a/streampipes-extensions/streampipes-processors-enricher-jvm/src/test/java/org/apache/streampipes/processors/enricher/jvm/processor/math/MathOpProcessorTest.java +++ b/streampipes-extensions/streampipes-processors-enricher-jvm/src/test/java/org/apache/streampipes/processors/enricher/jvm/processor/math/MathOpProcessorTest.java @@ -42,10 +42,12 @@ public void detectAdditionOperator() { .configWithDefaultPrefix(MathOpProcessor.RIGHT_OPERAND, "rightOperand") .config(MathOpProcessor.OPERATION, "+").build(); - List> inputEvents = List.of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); - List> outputEvents = List - .of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 10.0d)); - ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor(processor, leftOperandConfiguration); + List> inputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); + List> outputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 10.0d)); + ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor( + processor, leftOperandConfiguration); testExecutor.run(inputEvents, outputEvents); } @@ -57,10 +59,12 @@ public void detectSubtractionOperator() { .configWithDefaultPrefix(MathOpProcessor.RIGHT_OPERAND, "rightOperand") .config(MathOpProcessor.OPERATION, "-").build(); - List> inputEvents = List.of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); - List> outputEvents = List - .of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 0.0d)); - ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor(processor, leftOperandConfiguration); + List> inputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); + List> outputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 0.0d)); + ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor( + processor, leftOperandConfiguration); testExecutor.run(inputEvents, outputEvents); } @@ -72,10 +76,12 @@ public void detectMultiplicationOperator() { .configWithDefaultPrefix(MathOpProcessor.RIGHT_OPERAND, "rightOperand") .config(MathOpProcessor.OPERATION, "*").build(); - List> inputEvents = List.of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); - List> outputEvents = List - .of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 25.0d)); - ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor(processor, leftOperandConfiguration); + List> inputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); + List> outputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 25.0d)); + ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor( + processor, leftOperandConfiguration); testExecutor.run(inputEvents, outputEvents); } @@ -87,10 +93,12 @@ public void detectDivisionOperator() { .configWithDefaultPrefix(MathOpProcessor.RIGHT_OPERAND, "rightOperand") .config(MathOpProcessor.OPERATION, "/").build(); - List> inputEvents = List.of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); - List> outputEvents = List - .of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 1.0d)); - ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor(processor, leftOperandConfiguration); + List> inputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); + List> outputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 1.0d)); + ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor( + processor, leftOperandConfiguration); testExecutor.run(inputEvents, outputEvents); } @@ -102,11 +110,13 @@ public void detectModulusOperator() { .configWithDefaultPrefix(MathOpProcessor.RIGHT_OPERAND, "rightOperand") .config(MathOpProcessor.OPERATION, "%").build(); - List> inputEvents = List.of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); - List> outputEvents = List - .of(Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 0.0d)); - ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor(processor, leftOperandConfiguration); + List> inputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d)); + List> outputEvents = List.of( + Map.of("leftOperand", 5.0d, "rightOperand", 5.0d, "calculationResult", 0.0d)); + ProcessingElementTestExecutor testExecutor = new ProcessingElementTestExecutor( + processor, leftOperandConfiguration); testExecutor.run(inputEvents, outputEvents); } -} +} \ No newline at end of file