Use Case - AT #14066
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Use Case - AT | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '*/15 * * * *' | |
jobs: | |
test: | |
strategy: | |
fail-fast: false | |
matrix: | |
environment: [AT21, AT22, AT23, AT24] | |
environment: ${{ matrix.environment }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Run use case tests for data endpoint | |
run: | | |
cd test/k6 | |
docker-compose run k6 run /src/tests/data.js -e tokenGeneratorUserName=${{ secrets.TOKENGENERATOR_USERNAME }} -e tokenGeneratorUserPwd=${{ secrets.TOKENGENERATOR_USERPASSWORD }} -e env=${{ vars.ENV }} -e pid=${{ secrets.PERSON_NUMBER }} -e partyId=${{ secrets.PARTY_ID }} -e userId=${{ secrets.USER_ID }} -e org=${{ vars.ORG }} -e app=${{ vars.APP }} -e apimSubsKey=${{ secrets.APIM_SUBSKEY }} -e useTestTokenGenerator=true | |
- name: Run use case tests for sign endpoint | |
if: always() | |
run: | | |
cd test/k6 | |
docker-compose run k6 run /src/tests/sign.js -e tokenGeneratorUserName=${{ secrets.TOKENGENERATOR_USERNAME }} -e tokenGeneratorUserPwd=${{ secrets.TOKENGENERATOR_USERPASSWORD }} -e env=${{ vars.ENV }} -e pid=${{ secrets.PERSON_NUMBER }} -e partyId=${{ secrets.PARTY_ID }} -e userId=${{ secrets.USER_ID }} -e org=${{ vars.ORG }} -e app=${{ vars.APP }} -e apimSubsKey=${{ secrets.APIM_SUBSKEY }} -e useTestTokenGenerator=true | |
- name: Build failure report | |
if: failure() | |
run: | | |
report=":warning: Storage use case test failure in ${{ matrix.environment }} :warning: \n" | |
report+="\n Workflow available here: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" | |
echo "stepreport="$report >> $GITHUB_ENV | |
- name: Report failure to Slack | |
if: failure() | |
id: slack | |
uses: slackapi/[email protected] | |
with: | |
payload: | | |
{ | |
"text": "${{ env.stepreport }}" | |
} | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL_TEST }} | |