Skip to content

Commit

Permalink
Fixed loader e2e tests
Browse files Browse the repository at this point in the history
Signed-off-by: aryans1204 <arshar1204@gmail.com>
  • Loading branch information
aryans1204 authored and JooyoungPark73 committed Feb 10, 2025
1 parent b17fe62 commit d913372
Showing 1 changed file with 29 additions and 2 deletions.
31 changes: 29 additions & 2 deletions .github/workflows/e2e_loader.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
run: go run cmd/loader.go --config pkg/config/test_config.json

- name: Check the output
run: test -f "data/out/experiment_duration_5.csv" && test $(cat data/out/experiment_duration_5.csv | wc -l) -gt 1 && test $(grep true data/out/experiment_duration_5.csv | wc -l) -eq 0 # test the output file for errors (true means failure to invoke)
run: test -f "data/out/experiment_duration_2.csv" && test $(cat data/out/experiment_duration_2.csv | wc -l) -gt 1 && test $(grep true data/out/experiment_duration_2.csv | wc -l) -eq 0 # test the output file for errors (true means failure to invoke)

- name: Print logs
if: ${{ always() }}
Expand All @@ -54,4 +54,31 @@ jobs:
- name: Down
if: ${{ always() }}
run: |
kn service delete --all
kn service delete --all
- name: Untar vSwarm YAMLs
if: ${{ always() }}
run: |
tar -xzvf workloads/container/yamls.tar.gz -C workloads/container/
- name: Run vSwarm loader
run: go run cmd/loader.go --config pkg/config/test_vswarm_config.json

- name: Check vSwarm output
run: test -f "data/out/experiment_duration_2.csv" && test $(cat data/out/experiment_duration_2.csv | wc -l) -gt 1 && test $(grep true data/out/experiment_duration_2.csv | wc -l) -le 1 # test the output file for errors (true means failure to invoke)

- name: Print logs
if: ${{ always() }}
run: |
set -x
container_list=$(kubectl get pods -n default -o jsonpath="{.items[*].spec.containers[*].name}")
for container_name in $container_list
do
kubectl logs -n default -c $container_name -l serving.knative.dev/service=${{ matrix.service }}
done
- name: Down
if: ${{ always() }}
run: |
kn service delete --all


0 comments on commit d913372

Please sign in to comment.