This is an automated email from the ASF dual-hosted git repository.

zehnder pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-streampipes.git

commit 08e27baa4198369f3051d9920aeacb897446bebb
Author: Philipp Zehnder <[email protected]>
AuthorDate: Mon Oct 25 21:28:34 2021 +0200

    [STREAMPIPES-449] Add test for therhold detection
---
 .../filters-jvm/thresholdDetection1/description.json | 20 ++++++++++++++++++++
 .../filters-jvm/thresholdDetection1/expected.csv     | 11 +++++++++++
 .../filters-jvm/thresholdDetection1/input.csv        | 11 +++++++++++
 .../tests/pipelineElement/SinglePipelineElement.ts   |  2 +-
 4 files changed, 43 insertions(+), 1 deletion(-)

diff --git 
a/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/description.json
 
b/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/description.json
new file mode 100644
index 0000000..54580f1
--- /dev/null
+++ 
b/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/description.json
@@ -0,0 +1,20 @@
+{
+  "name": "threshold_detector",
+  "config": [
+    {
+      "type": "drop-down",
+      "selector": "number-mapping",
+      "value": "randomnumber"
+    },
+    {
+      "type": "radio",
+      "selector": "operation",
+      "value": "\\>"
+    },
+    {
+      "type": "input",
+      "selector": "value",
+      "value": "50"
+    }
+  ]
+}
\ No newline at end of file
diff --git 
a/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/expected.csv
 
b/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/expected.csv
new file mode 100644
index 0000000..399ebd4
--- /dev/null
+++ 
b/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/expected.csv
@@ -0,0 +1,11 @@
+time;randomnumber;thresholddetected
+1623871499055;62.0;true
+1623871500059;46.0;false
+1623871501064;41.0;false
+1623871502007;41.0;false
+1623871503078;22.0;false
+1623871504082;56.0;true
+1623871505084;95.0;true
+1623871506086;77.0;true
+1623871507091;85.0;true
+1623871508093;22.0;false
\ No newline at end of file
diff --git 
a/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/input.csv 
b/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/input.csv
new file mode 100644
index 0000000..c5fb22e
--- /dev/null
+++ 
b/ui/cypress/fixtures/pipelineElement/filters-jvm/thresholdDetection1/input.csv
@@ -0,0 +1,11 @@
+timestamp;randomnumber
+1623871499055;62.0
+1623871500059;46.0
+1623871501064;41.0
+1623871502070;41.0
+1623871503078;22.0
+1623871504082;56.0
+1623871505084;95.0
+1623871506086;77.0
+1623871507091;85.0
+1623871508093;22.0
diff --git a/ui/cypress/tests/pipelineElement/SinglePipelineElement.ts 
b/ui/cypress/tests/pipelineElement/SinglePipelineElement.ts
index 7c5cbaa..df059b0 100644
--- a/ui/cypress/tests/pipelineElement/SinglePipelineElement.ts
+++ b/ui/cypress/tests/pipelineElement/SinglePipelineElement.ts
@@ -22,7 +22,7 @@ import { ProcessorTest } from 
'../../support/model/ProcessorTest';
 const allTests = Cypress.env('processingElements');
 
 allTests.forEach(test => {
-  const testName = 'valueChange1';
+  const testName = 'thresholdDetection1';
 
   const processorTest = test as ProcessorTest;
 

Reply via email to