Skip to content

Commit

Permalink
feat: core tests - Artillery distributed workflow (#6201)
Browse files Browse the repository at this point in the history
* cypress revision fixed

* core tests - artillery distributed workflow

* artillery workflow suite extended with distributed example

* small suite extended with cypress workflow

* workflow example namespace removed
  • Loading branch information
tkonieczny authored Feb 26, 2025
1 parent 4d1fa82 commit 87a42c1
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 8 deletions.
64 changes: 58 additions & 6 deletions test/artillery/executor-smoke/crd-workflow/smoke.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,10 @@ spec:
cpu: 128m
memory: 256Mi
workingDir: /data/repo/test/artillery/executor-smoke
image: artilleryio/artillery:2.0.22
steps:
- name: Run test
run:
image: artilleryio/artillery:2.0.9
args:
- run
- artillery-smoke-test.yaml
shell: /home/node/artillery/bin/run run artillery-smoke-test.yaml
---
apiVersion: testworkflows.testkube.io/v1
kind: TestWorkflow
Expand All @@ -50,5 +47,60 @@ spec:
template:
name: official/artillery/v1
config:
version: 2.0.9
version: 2.0.22
run: "artillery run artillery-smoke-test.yaml"
---
kind: TestWorkflow
apiVersion: testworkflows.testkube.io/v1
metadata:
name: distributed-artillery-workflow-smoke-artifacts
labels:
core-tests: workflows
spec:
config:
arrivalRatePerWorker:
type: integer
default: 2
duration:
type: string
default: 2
workers:
type: integer
default: 2
content:
git:
uri: https://github.com/kubeshop/testkube
revision: main
paths:
- test/artillery/executor-smoke/artillery-smoke-test.yaml
container:
image: artilleryio/artillery:2.0.20
steps:
- name: Run test
parallel:
count: config.workers
transfer:
- from: /data/repo
fetch:
- from: /data/artifacts
use:
- name: distribute/evenly
container:
image: artilleryio/artillery:2.0.20
resources:
requests:
cpu: 128m
memory: 256Mi
paused: true
run:
workingDir: /data/repo/test/artillery/executor-smoke
shell: "mkdir -p /data/artifacts && /home/node/artillery/bin/run run artillery-smoke-test.yaml --overrides '{ \"phases\": [{ \"duration\": {{ config.duration }}, \"arrivalRate\": {{ config.arrivalRatePerWorker }} }] }' -o /data/artifacts/report-{{ index }}.json"
- name: Generate HTML report # The "report" command is deprecated and will be removed in a future release of Artillery.
shell: mkdir html && for file in *.json; do /home/node/artillery/bin/run report "$file" -o "html/${file%.json}.html"; done
workingDir: /data/artifacts
- name: Save artifacts
condition: always
artifacts:
workingDir: /data/artifacts
paths:
- '**/*'
4 changes: 2 additions & 2 deletions test/cypress/executor-tests/crd-workflow/smoke.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ spec:
content:
git:
uri: https://github.com/kubeshop/testkube
revision: cypress-14-project-and-cleanup # TODO: update before merge
revision: main
paths:
- test/cypress/executor-tests/cypress-14
container:
Expand Down Expand Up @@ -46,7 +46,7 @@ spec:
content:
git:
uri: https://github.com/kubeshop/testkube
revision: cypress-14-project-and-cleanup # TODO: update before merge
revision: main
paths:
- test/cypress/executor-tests/cypress-14
container:
Expand Down
1 change: 1 addition & 0 deletions test/suites/test-workflows/artillery-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ spec:
workflows:
- name: artillery-workflow-smoke
- name: artillery-workflow-smoke-template
- name: distributed-artillery-workflow-smoke-artifacts
1 change: 1 addition & 0 deletions test/suites/test-workflows/small-smoke.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ spec:
- name: postman-workflow-smoke-template
- name: soapui-workflow-smoke
- name: pytest-workflow-smoke-junit-success-only
- name: cypress-workflow-smoke-14

0 comments on commit 87a42c1

Please sign in to comment.