Skip to content

Use Case - AT

Use Case - AT #49662

Workflow file for this run

name: Use Case - AT
on:
workflow_dispatch:
schedule:
- cron: '*/15 * * * *'
jobs:
test:
strategy:
fail-fast: false
matrix:
environment: [AT22, AT23, AT24]
environment: ${{ matrix.environment }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run use case tests for endpoint 'applications'
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/applications.js
flags: -e env=${{ vars.ENV }} -e org=${{ vars.ORG }} -e app=${{ vars.APP }}
- name: Run use case tests for endpoint 'instances'
if: always()
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/instances.js
flags: -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 endpoint 'instances/sbl'
if: always()
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/messageboxinstances.js
flags: -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 apimSblSubsKey=${{ secrets.APIM_SBL_SUBSKEY }} -e useTestTokenGenerator=true
- name: Run use case tests for endpoint 'data'
if: always()
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/data.js
flags: -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 endpoint 'process'
if: always()
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/process.js
flags: -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 endpoint 'sign'
if: always()
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/sign.js
flags: -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 endpoint 'texts'
if: always()
uses: grafana/[email protected]
with:
filename: test/k6/src/tests/texts.js
flags: -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 }}