memory-tests #955
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: memory-tests | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: 0 21 * * * | |
jobs: | |
tests: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 18 | |
cache: 'yarn' | |
- run: yarn install --frozen-lockfile | |
name: install root | |
- run: yarn workspace @sap-cloud-sdk/e2e-tests pretest:e2e | |
name: start e2e tests server | |
- run: yarn install | |
name: install test v2 | |
working-directory: test-packages/memory-tests/sdk-v2/ | |
- run: yarn generate-vdm | |
name: generate v2 test client | |
working-directory: test-packages/memory-tests/sdk-v2/ | |
- run: node --inspect test-script.js && cat result.txt | |
working-directory: test-packages/memory-tests/sdk-v2/ | |
- run: yarn install | |
name: install test canary | |
working-directory: test-packages/memory-tests/sdk-canary/ | |
- run: yarn generate-vdm | |
name: generate canary test client | |
working-directory: test-packages/memory-tests/sdk-canary/ | |
- run: node --inspect test-script.js && cat result.txt | |
working-directory: test-packages/memory-tests/sdk-canary/ | |
- run: yarn ts-node scripts/compare-memory-usage.ts $(cat ./test-packages/memory-tests/sdk-v2/result.txt) $(cat ./test-packages/memory-tests/sdk-canary/result.txt) | |
name: compare v2 and canary | |
- if: failure() || cancelled() | |
name: Slack Notify | |
uses: rtCamp/[email protected] | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | |
SLACK_USERNAME: SDK Pipeline Bot | |
SLACK_TITLE: Memory tests ${{ job.status }} | |
SLACK_MESSAGE: 'Test failed' | |
MSG_MINIMAL: event,actions url | |
SLACK_COLOR: ${{ job.status }} | |
SLACK_MSG_AUTHOR: ' ' | |
SLACK_ICON: https://sap.github.io/cloud-sdk/img/logo.png |