Integration Tests for Deployed API #33145
This file contains hidden or 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: Integration Tests for Deployed API | |
| permissions: | |
| contents: read | |
| on: | |
| schedule: | |
| - cron: '*/30 * * * *' | |
| workflow_dispatch: | |
| jobs: | |
| integration_tests: | |
| if: ${{ github.repository == 'nsls2/nsls2api' }} # Do not run on forks | |
| runs-on: self-hosted | |
| steps: | |
| - name: Print hostname | |
| run: echo "The hostname is $(hostname)" | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| with: | |
| persist-credentials: false | |
| - name: Setup Java | |
| uses: actions/setup-java@v5 | |
| with: | |
| distribution: 'zulu' | |
| java-version: '21' | |
| - name: Download ijhttp.zip | |
| run: curl -f -L -o ijhttp.zip "https://jb.gg/ijhttp/latest" | |
| - name: Unzip ijhttp.zip | |
| run: unzip -q ijhttp.zip | |
| - name: Beamline endpoint tests | |
| run: | | |
| ./ijhttp/ijhttp --env-file ./integration-tests/http-client.env.json \ | |
| --env production \ | |
| ./integration-tests/check_all_beamlines.http | |
| - name: Check API Service | |
| run: | | |
| ./ijhttp/ijhttp --env-file ./integration-tests/http-client.env.json \ | |
| --env production \ | |
| ./integration-tests/check_service_health.http |