You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@streampipes.apache.org by ze...@apache.org on 2021/11/30 10:10:56 UTC

[incubator-streampipes] 14/21: [STREAMPIPES-478] Add data explorer tests to smoke tests

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 e8c2e58dbf088c3a2dd86a09648acfa5f4f6fc3e
Author: Philipp Zehnder <ze...@fzi.de>
AuthorDate: Mon Nov 29 06:55:49 2021 +0100

    [STREAMPIPES-478] Add data explorer tests to smoke tests
---
 ui/cypress/support/utils/AdapterUtils.ts                            | 2 +-
 ui/cypress/support/utils/DataLakeUtils.ts                           | 6 ++++--
 .../tests/adapter/{fileStream.smoke.ts => fileStream.smoke.spec.ts} | 0
 ...ineDataSimulator.smoke.ts => machineDataSimulator.smoke.spec.ts} | 0
 .../{persistInDataLake.smoke.ts => persistInDataLake.smoke.spec.ts} | 0
 .../datalake/{configuration.spec.ts => configuration.smoke.spec.ts} | 0
 ...ecialCharactersInName.spec.ts => testSpecialCharactersInName.ts} | 0
 ...aConfiguration.spec.ts => widgetDataConfiguration.smoke.spec.ts} | 0
 ui/cypress/tests/datalake/widgets/{table.spec.ts => table.ts}       | 0
 ...testFileManagement.smoke.ts => testFileManagement.smoke.spec.ts} | 0
 ui/cypress/tests/login/{login.smoke.ts => login.smoke.spec.ts}      | 0
 .../pipeline/{pipelineTest.smoke.ts => pipelineTest.smoke.spec.ts}  | 0
 .../{SinglePipelineElement.spec.ts => SinglePipelineElement.ts}     | 0
 ui/cypress/tests/thirdparty/{InfluxDb.spec.ts => InfluxDb.ts}       | 0
 ui/cypress/tests/thirdparty/{Kafka.spec.ts => Kafka.ts}             | 0
 ui/cypress/tests/thirdparty/{Mqtt.spec.ts => Mqtt.ts}               | 0
 ui/cypress/tests/thirdparty/{MySQLDb.spec.ts => MySQLDb.ts}         | 0
 .../{addUserAdmin.spec.ts => addUserAdmin.smoke.spec.ts}            | 0
 ...ExplorerAdmin.spec.ts => addUserDataExplorerAdmin.smoke.spec.ts} | 0
 ui/package.json                                                     | 3 ++-
 20 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/ui/cypress/support/utils/AdapterUtils.ts b/ui/cypress/support/utils/AdapterUtils.ts
index 232f015..5702a66 100644
--- a/ui/cypress/support/utils/AdapterUtils.ts
+++ b/ui/cypress/support/utils/AdapterUtils.ts
@@ -182,7 +182,7 @@ export class AdapterUtils {
 
     // Start adapter
     cy.get('#button-startAdapter').click();
-    cy.dataCy(successElement, { timeout: 20000 }).should('be.visible');
+    cy.dataCy(successElement, { timeout: 30000 }).should('be.visible');
 
     // Close adapter preview
     cy.get('button').contains('Close').parent().click();
diff --git a/ui/cypress/support/utils/DataLakeUtils.ts b/ui/cypress/support/utils/DataLakeUtils.ts
index 3c54acf..35f7421 100644
--- a/ui/cypress/support/utils/DataLakeUtils.ts
+++ b/ui/cypress/support/utils/DataLakeUtils.ts
@@ -183,8 +183,10 @@ export class DataLakeUtils {
   }
 
   public static selectTimeRange(from: Date, to: Date) {
-    DataLakeUtils.setTimeInput('time-range-from', from);
-    DataLakeUtils.setTimeInput('time-range-to', to);
+    cy.dataCy('1_year').click();
+    // TODO fix time range selection
+    // DataLakeUtils.setTimeInput('time-range-from', from);
+    // DataLakeUtils.setTimeInput('time-range-to', to);
   }
 
   private static setTimeInput(selector: string, value: Date) {
diff --git a/ui/cypress/tests/adapter/fileStream.smoke.ts b/ui/cypress/tests/adapter/fileStream.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/adapter/fileStream.smoke.ts
rename to ui/cypress/tests/adapter/fileStream.smoke.spec.ts
diff --git a/ui/cypress/tests/adapter/machineDataSimulator.smoke.ts b/ui/cypress/tests/adapter/machineDataSimulator.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/adapter/machineDataSimulator.smoke.ts
rename to ui/cypress/tests/adapter/machineDataSimulator.smoke.spec.ts
diff --git a/ui/cypress/tests/adapter/persistInDataLake.smoke.ts b/ui/cypress/tests/adapter/persistInDataLake.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/adapter/persistInDataLake.smoke.ts
rename to ui/cypress/tests/adapter/persistInDataLake.smoke.spec.ts
diff --git a/ui/cypress/tests/datalake/configuration.spec.ts b/ui/cypress/tests/datalake/configuration.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/datalake/configuration.spec.ts
rename to ui/cypress/tests/datalake/configuration.smoke.spec.ts
diff --git a/ui/cypress/tests/datalake/testSpecialCharactersInName.spec.ts b/ui/cypress/tests/datalake/testSpecialCharactersInName.ts
similarity index 100%
rename from ui/cypress/tests/datalake/testSpecialCharactersInName.spec.ts
rename to ui/cypress/tests/datalake/testSpecialCharactersInName.ts
diff --git a/ui/cypress/tests/datalake/widgetDataConfiguration.spec.ts b/ui/cypress/tests/datalake/widgetDataConfiguration.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/datalake/widgetDataConfiguration.spec.ts
rename to ui/cypress/tests/datalake/widgetDataConfiguration.smoke.spec.ts
diff --git a/ui/cypress/tests/datalake/widgets/table.spec.ts b/ui/cypress/tests/datalake/widgets/table.ts
similarity index 100%
rename from ui/cypress/tests/datalake/widgets/table.spec.ts
rename to ui/cypress/tests/datalake/widgets/table.ts
diff --git a/ui/cypress/tests/fileManagement/testFileManagement.smoke.ts b/ui/cypress/tests/fileManagement/testFileManagement.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/fileManagement/testFileManagement.smoke.ts
rename to ui/cypress/tests/fileManagement/testFileManagement.smoke.spec.ts
diff --git a/ui/cypress/tests/login/login.smoke.ts b/ui/cypress/tests/login/login.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/login/login.smoke.ts
rename to ui/cypress/tests/login/login.smoke.spec.ts
diff --git a/ui/cypress/tests/pipeline/pipelineTest.smoke.ts b/ui/cypress/tests/pipeline/pipelineTest.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/pipeline/pipelineTest.smoke.ts
rename to ui/cypress/tests/pipeline/pipelineTest.smoke.spec.ts
diff --git a/ui/cypress/tests/pipelineElement/SinglePipelineElement.spec.ts b/ui/cypress/tests/pipelineElement/SinglePipelineElement.ts
similarity index 100%
rename from ui/cypress/tests/pipelineElement/SinglePipelineElement.spec.ts
rename to ui/cypress/tests/pipelineElement/SinglePipelineElement.ts
diff --git a/ui/cypress/tests/thirdparty/InfluxDb.spec.ts b/ui/cypress/tests/thirdparty/InfluxDb.ts
similarity index 100%
rename from ui/cypress/tests/thirdparty/InfluxDb.spec.ts
rename to ui/cypress/tests/thirdparty/InfluxDb.ts
diff --git a/ui/cypress/tests/thirdparty/Kafka.spec.ts b/ui/cypress/tests/thirdparty/Kafka.ts
similarity index 100%
rename from ui/cypress/tests/thirdparty/Kafka.spec.ts
rename to ui/cypress/tests/thirdparty/Kafka.ts
diff --git a/ui/cypress/tests/thirdparty/Mqtt.spec.ts b/ui/cypress/tests/thirdparty/Mqtt.ts
similarity index 100%
rename from ui/cypress/tests/thirdparty/Mqtt.spec.ts
rename to ui/cypress/tests/thirdparty/Mqtt.ts
diff --git a/ui/cypress/tests/thirdparty/MySQLDb.spec.ts b/ui/cypress/tests/thirdparty/MySQLDb.ts
similarity index 100%
rename from ui/cypress/tests/thirdparty/MySQLDb.spec.ts
rename to ui/cypress/tests/thirdparty/MySQLDb.ts
diff --git a/ui/cypress/tests/userManagement/addUserAdmin.spec.ts b/ui/cypress/tests/userManagement/addUserAdmin.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/userManagement/addUserAdmin.spec.ts
rename to ui/cypress/tests/userManagement/addUserAdmin.smoke.spec.ts
diff --git a/ui/cypress/tests/userManagement/addUserDataExplorerAdmin.spec.ts b/ui/cypress/tests/userManagement/addUserDataExplorerAdmin.smoke.spec.ts
similarity index 100%
rename from ui/cypress/tests/userManagement/addUserDataExplorerAdmin.spec.ts
rename to ui/cypress/tests/userManagement/addUserDataExplorerAdmin.smoke.spec.ts
diff --git a/ui/package.json b/ui/package.json
index 99fc715..5ec415f 100644
--- a/ui/package.json
+++ b/ui/package.json
@@ -15,7 +15,8 @@
     "lint": "tslint -c tslint.json 'src/**/*.ts*",
     "analyze": "webpack-bundle-analyzer dist/stats.json",
     "test-e2e": "cypress open",
-    "test-cypress-github": "npx cypress run --spec 'cypress/tests/**/*.smoke.ts'"
+    "test-cypress-smoke": "npx cypress run --spec 'cypress/tests/**/*.smoke.spec.ts'",
+    "test-cypress-all": "npx cypress run --spec 'cypress/tests/**/*.ts'"
   },
   "dependencies": {
     "@angular/animations": "12.2.9",