Skip to content

Commit

Permalink
chore(test): use venom 1.0.0 (#5568)
Browse files Browse the repository at this point in the history
  • Loading branch information
yesnault authored Dec 1, 2020
1 parent a16b385 commit 4195f31
Show file tree
Hide file tree
Showing 48 changed files with 58 additions and 86 deletions.
2 changes: 0 additions & 2 deletions tests/00_smoke_test_api.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
name: Smoke tests

vars:
api.url: 'http://localhost:8081'
cdsctl : 'cdsctl'


testcases:
- name: Check API is UP and RUNNING
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/01_queue_stopall.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Queue stop all
version: "2"
testcases:
- name: cdsctl queue stopall
steps:
Expand Down
4 changes: 0 additions & 4 deletions tests/01_signup.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: signup tests

vars:
api.url: 'http://localhost:8081'
ui.url: 'http://localhost:8080'
Expand All @@ -12,7 +11,6 @@ vars:
fullname: IT_User_RW
password: "123456&éçà(§"


testcases:
- name: Check SMTP mock
steps:
Expand All @@ -34,7 +32,6 @@ testcases:
body: |-
{ "username": "{{.username}}", "fullname": "{{.fullname}}", "email":"{{.email}}", "password": "{{.password}}" }
- name: post-create-user
steps:
- type: http
Expand All @@ -49,7 +46,6 @@ testcases:
from: result.bodyjson.content-decoded
regex: cdsctl signup verify --api-url (?:.*) (.*)


- name: prepare-cdsctl-config-file
steps:
- script: "rm -f {{.cdsctl.config}}"
Expand Down
2 changes: 0 additions & 2 deletions tests/02_smoke_test_services.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
name: Smoke tests

vars:
ui.url: 'http://localhost:8080'
hatchery.url: 'http://localhost:8086'
hooks.url: 'http://localhost:8083'


testcases:
- name: Check UI, Hatchery are UP and RUNNING
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_action.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Action Command TestSuite with cdsctl
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
2 changes: 0 additions & 2 deletions tests/03_clictl_admin_broadcast.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Broadcast Command TestSuite
version: "2"
testcases:
- name: broadcast
steps:
Expand All @@ -11,4 +10,3 @@ testcases:
- script: {{.cdsctl}} -f {{.cdsctl.config}} admin broadcasts list | grep "the title"
- script: {{.cdsctl}} -f {{.cdsctl.config}} admin broadcasts show `{{.cdsctl}} -f {{.cdsctl.config}} admin broadcasts list | grep "the title" | cut -d "|" -f6|head -n 1`
- script: {{.cdsctl}} -f {{.cdsctl.config}} admin broadcasts delete `{{.cdsctl}} -f {{.cdsctl.config}} admin broadcasts list | grep "the title" | cut -d "|" -f6|head -n 1`

1 change: 0 additions & 1 deletion tests/03_clictl_admin_database.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Database Commands TestSuite
version: "2"
testcases:
- name: delete an invalid row from gorp_migration
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_admin_integration_model.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Integration model admin
version: "2"
testcases:
- name: prepare test
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_admin_metadata.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: cdsctl admin metadata Command TestSuite
version: "2"
testcases:
- name: admin meta
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_admin_plugin_and_integrations.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Plugins Command TestSuite with cdsctl
version: "2"
testcases:
- name: cdsctl admin plugins list
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_admin_services.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Action Command TestSuite with cdsctl
version: "2"
testcases:
- name: cdsctl admin services list
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_common_options.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Common options test for cdsctl
version: "2"
testcases:
- name: prepare test data
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_group.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Group Command TestSuite
version: "2"
testcases:
- name: prepare test
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_project.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Project Command TestSuite with CDS ctl
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
26 changes: 19 additions & 7 deletions tests/03_clictl_template.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Template command TestSuite with cdsctl
version: "2"
testcases:
- name: push example with repository
steps:
Expand All @@ -18,6 +17,19 @@ testcases:
steps:
- type: readfile
path: ./fixtures/template/with_repository/*.yml
vars:
md5sum_fixtures_template_with_repository_1.application:
from: result.md5sum.fixtures_template_with_repository_1.application.yml
md5sum_fixtures_template_with_repository_1.environment:
from: result.md5sum.fixtures_template_with_repository_1.environment.yml
md5sum_fixtures_template_with_repository_1.pipeline:
from: result.md5sum.fixtures_template_with_repository_1.pipeline.yml
md5sum_fixtures_template_with_repository_2.pipeline:
from: result.md5sum.fixtures_template_with_repository_2.pipeline.yml
md5sum_fixtures_template_with_repository_example-with-repository:
from: result.md5sum.fixtures_template_with_repository_example-with-repository.yml
md5sum_fixtures_template_with_repository_workflow:
from: result.md5sum.fixtures_template_with_repository_workflow.yml
assertions:
- result.err ShouldEqual ""

Expand All @@ -27,9 +39,9 @@ testcases:
path: ./fixtures/template/with_repository/export/*.yml
assertions:
- result.err ShouldEqual ""
- result.md5sum.fixtures_template_with_repository_export_1.application.yml ShouldEqual "{{.readTemplateSourceFiles.result.md5sum.fixtures_template_with_repository_1.application.yml}}"
- result.md5sum.fixtures_template_with_repository_export_1.environment.yml ShouldEqual "{{.readTemplateSourceFiles.result.md5sum.fixtures_template_with_repository_1.environment.yml}}"
- result.md5sum.fixtures_template_with_repository_export_1.pipeline.yml ShouldEqual "{{.readTemplateSourceFiles.result.md5sum.fixtures_template_with_repository_1.pipeline.yml}}"
- result.md5sum.fixtures_template_with_repository_export_2.pipeline.yml ShouldEqual "{{.readTemplateSourceFiles.result.md5sum.fixtures_template_with_repository_2.pipeline.yml}}"
- result.md5sum.fixtures_template_with_repository_export_example-with-repository.yml ShouldEqual "{{.readTemplateSourceFiles.result.md5sum.fixtures_template_with_repository_example-with-repository.yml}}"
- result.md5sum.fixtures_template_with_repository_export_workflow.yml ShouldEqual "{{.readTemplateSourceFiles.result.md5sum.fixtures_template_with_repository_workflow.yml}}"
- result.md5sum.fixtures_template_with_repository_export_1.application.yml ShouldEqual "{{.readTemplateSourceFiles.md5sum_fixtures_template_with_repository_1.application}}"
- result.md5sum.fixtures_template_with_repository_export_1.environment.yml ShouldEqual "{{.readTemplateSourceFiles.md5sum_fixtures_template_with_repository_1.environment}}"
- result.md5sum.fixtures_template_with_repository_export_1.pipeline.yml ShouldEqual "{{.readTemplateSourceFiles.md5sum_fixtures_template_with_repository_1.pipeline}}"
- result.md5sum.fixtures_template_with_repository_export_2.pipeline.yml ShouldEqual "{{.readTemplateSourceFiles.md5sum_fixtures_template_with_repository_2.pipeline}}"
- result.md5sum.fixtures_template_with_repository_export_example-with-repository.yml ShouldEqual "{{.readTemplateSourceFiles.md5sum_fixtures_template_with_repository_example-with-repository}}"
- result.md5sum.fixtures_template_with_repository_export_workflow.yml ShouldEqual "{{.readTemplateSourceFiles.md5sum_fixtures_template_with_repository_workflow}}"
6 changes: 4 additions & 2 deletions tests/03_clictl_template_apply.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Template apply command TestSuite with cdsctl
version: "2"
testcases:
- name: delete template if exists
steps:
Expand Down Expand Up @@ -32,6 +31,9 @@ testcases:
steps:
- type: readfile
path: ./fixtures/template/simple/workflow/*.yml
vars:
md5sum_fixtures_template_simple_workflow_itcliwkf:
from: result.md5sum.fixtures_template_simple_workflow_itcliwkf.yml
assertions:
- result.err ShouldEqual ""

Expand All @@ -41,7 +43,7 @@ testcases:
path: ./fixtures/template/simple/export/*.yml
assertions:
- result.err ShouldEqual ""
- result.md5sum.fixtures_template_simple_export_itcliwkf.yml ShouldEqual "{{.readWorkflowSourceFiles.result.md5sum.fixtures_template_simple_workflow_itcliwkf.yml}}"
- result.md5sum.fixtures_template_simple_export_itcliwkf.yml ShouldEqual "{{.readWorkflowSourceFiles.md5sum_fixtures_template_simple_workflow_itcliwkf}}"

- name: cdsctl template instances
steps:
Expand Down
18 changes: 13 additions & 5 deletions tests/03_clictl_template_apply_detached.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Template apply detached command TestSuite with cdsctl
version: "2"
testcases:
- name: delete template if exists
steps:
Expand Down Expand Up @@ -30,14 +29,23 @@ testcases:
path: ./fixtures/template/simple/workflow-detached/*.yml
assertions:
- result.err ShouldEqual ""
vars:
md5sum_fixtures_template_simple_workflow-detached_first-environment:
from: result.md5sum.fixtures_template_simple_workflow-detached_first-environment.env.yml
md5sum_fixtures_template_simple_workflow-detached_first-pipeline:
from: result.md5sum.fixtures_template_simple_workflow-detached_first-pipeline.pip.yml
md5sum_fixtures_template_simple_workflow-detached_second-pipeline:
from: result.md5sum.fixtures_template_simple_workflow-detached_second-pipeline.pip.yml
md5sum_fixtures_template_simple_workflow-detached_itcliwkf:
from: result.md5sum.fixtures_template_simple_workflow-detached_itcliwkf.yml

- name: compare generated files with source
steps:
- type: readfile
path: ./fixtures/template/simple/export-detached/*.yml
assertions:
- result.err ShouldEqual ""
- result.md5sum.fixtures_template_simple_export-detached_first-environment.env.yml ShouldEqual "{{.readWorkflowSourceFiles.result.md5sum.fixtures_template_simple_workflow-detached_first-environment.env.yml}}"
- result.md5sum.fixtures_template_simple_export-detached_first-pipeline.pip.yml ShouldEqual "{{.readWorkflowSourceFiles.result.md5sum.fixtures_template_simple_workflow-detached_first-pipeline.pip.yml}}"
- result.md5sum.fixtures_template_simple_export-detached_second-pipeline.pip.yml ShouldEqual "{{.readWorkflowSourceFiles.result.md5sum.fixtures_template_simple_workflow-detached_second-pipeline.pip.yml}}"
- result.md5sum.fixtures_template_simple_export-detached_itcliwkf.yml ShouldEqual "{{.readWorkflowSourceFiles.result.md5sum.fixtures_template_simple_workflow-detached_itcliwkf.yml}}"
- result.md5sum.fixtures_template_simple_export-detached_first-environment.env.yml ShouldEqual "{{.readWorkflowSourceFiles.md5sum_fixtures_template_simple_workflow-detached_first-environment}}"
- result.md5sum.fixtures_template_simple_export-detached_first-pipeline.pip.yml ShouldEqual "{{.readWorkflowSourceFiles.md5sum_fixtures_template_simple_workflow-detached_first-pipeline}}"
- result.md5sum.fixtures_template_simple_export-detached_second-pipeline.pip.yml ShouldEqual "{{.readWorkflowSourceFiles.md5sum_fixtures_template_simple_workflow-detached_second-pipeline}}"
- result.md5sum.fixtures_template_simple_export-detached_itcliwkf.yml ShouldEqual "{{.readWorkflowSourceFiles.md5sum_fixtures_template_simple_workflow-detached_itcliwkf}}"
9 changes: 5 additions & 4 deletions tests/03_clictl_template_bulk.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Template bulk command TestSuite with cdsctl
version: "2"
testcases:
- name: push example simple
steps:
Expand All @@ -18,14 +17,16 @@ testcases:
- name: sendTemplateBulkRequest
steps:
- script: {{.cdsctl}} -f {{.cdsctl.config}} template bulk --instances-file ./fixtures/template/bulk_request.yml --no-interactive
vars:
bulkid:
from: result.systemout
regex: Bulk request with id ([0-9]+) successfully created for template shared.infra/example-simple with (?:[0-9]+) operations
assertions:
- result.code ShouldEqual 0
extracts:
result.systemout: Bulk request with id {{bulkID=[0-9]+}} successfully created for template shared.infra/example-simple with {{operationCount=[0-9]+}} operations

- name: check bulk request status
steps:
- script: {{.cdsctl}} -f {{.cdsctl.config}} admin curl /template/shared.infra/example-simple/bulk/{{.sendTemplateBulkRequest.bulkID}}
- script: {{.cdsctl}} -f {{.cdsctl.config}} admin curl /template/shared.infra/example-simple/bulk/{{.sendTemplateBulkRequest.bulkid}}
retry: 10
delay: 2
assertions:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_user.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: User Command TestSuite
version: "2"
testcases:
- name: cds user
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_version.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Version Command TestSuite
version: "2"
testcases:
- name: cds version
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_clictl_worker_model.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Worker Command TestSuite
version: "2"
testcases:
- name: prepare test
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/03_engine_download_workers.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Worker Command TestSuite
version: "2"
testcases:
- name: prepare test
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_create_run_join.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW3) and run it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_create_simple.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW1) and pull it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_edit_scheduler.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Workflow (ITSCWRKFLW16) update workflow with scheduler
version: "2"
testcases:
- name: assert filepath
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_git_clone_tag.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW6) and run it to test gitClone action
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_integration_deploy_plugin_req.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW15) run it and then stop it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_run_check_payload.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW8)
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_run_node_perm.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW10) and try to run it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
2 changes: 0 additions & 2 deletions tests/04_sc_workflow_run_notif.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
name: Create a simple workflow (04SCWorkflowRunNotif) that use worker export command, then check notif send
version: "2"

vars :
smtpmock.url: 'http://localhost:2024'

Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_run_simple_plugin.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Deploy a plugin and Create a simple workflow (04SCWorkflowRunSimplePlugin) that use it and run it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_run_simple_service.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (04SCWorkflowRunSimpleService) that use a service and run it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_run_worker_cmd.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (04SCWorkflowRunWorkerCmd) that use all worker command and run it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_run_worker_cmd_cache.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (04SCWorkflowRunWorkerCmdCache) that use worker cache command and run it to test absolute and relative path
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_simple_serve.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW7)
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_template_run.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Push a template and run this template
version: "2"
testcases:
- name: prepare test
steps:
Expand Down
1 change: 0 additions & 1 deletion tests/04_sc_workflow_update_run.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Create a simple workflow (ITSCWRKFLW2), update it and run it
version: "2"
testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
2 changes: 0 additions & 2 deletions tests/05_sc_workflow_event_kafka.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
name: Workflow (ITSCWRKFLW18) should use the kafka integration
version: "2"

testcases:
- name: assert filepath, your current directory must be at the root of this project
steps:
Expand Down
5 changes: 2 additions & 3 deletions tests/05_sc_workflow_storage_awss3_artifact.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
name: Workflow (ITSCWRKFLW11) should use the action artifact upload / download with integration aws s3
version: "2"

vars:
aws_default_region: ''
s3_bucket: ''
Expand All @@ -22,7 +20,8 @@ testcases:

- name: import integration
steps:
- script: {{.cdsctl}} -f {{.cdsctl.config}} project integration import ITSCWRKFLW11 {{expandEnv ./fixtures/integrations/s3Integration.yml}}
- script: envsubst < ./fixtures/integrations/s3Integration.yml > ./fixtures/integrations/s3Integration.replaced.yml
- script: {{.cdsctl}} -f {{.cdsctl.config}} project integration import ITSCWRKFLW11 ./fixtures/integrations/s3Integration.replaced.yml

- name: import workflow
steps:
Expand Down
Loading

0 comments on commit 4195f31

Please sign in to comment.