Skip to content

Commit

Permalink
Refactor.
Browse files Browse the repository at this point in the history
  • Loading branch information
everaldorodrigo committed Aug 16, 2024
1 parent 490f062 commit 4b94c62
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/scheduled_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,19 +74,22 @@ jobs:
echo "BUILD_VERSION_S3=$BUILD_VERSION_S3" >> $GITHUB_ENV
- name: Get release version from the Hub
id: http_request
run: |
response=$(curl -s "https://mygene.info/metadata")
echo "Response: $response"
echo "BUILD_VERSION_HUB=$(echo $response | jq -r .build_version)" >> $GITHUB_ENV
echo "### Old Build Version ${{ env.BUILD_VERSION_S3 }}"
echo "### New Build Version: $BUILD_VERSION_HUB"
if [[ "${{ env.BUILD_VERSION_HUB }}" != "$BUILD_VERSION_S3" ]]; then
- name: Run pytest if needed
run: |
echo "### S3 Build Version: ${{ env.BUILD_VERSION_S3 }}"
echo "### Hub Build Version: ${{ env.BUILD_VERSION_HUB }}"
if [[ "${{ env.BUILD_VERSION_HUB }}" != "${{ env.BUILD_VERSION_S3 }}" ]]; then
source .venv/bin/activate
cp .venv/lib/python3.11/site-packages/biothings/tests/conftest_slack/conftest.py src/tests/
python -m pytest src/tests/test_remote.py --slack-webhook-url=${{ secrets.SLACK_WEBHOOK_URL }} --slack-channel="#observability-test" --slack-username="Mygeneset.Info Tests"
rm src/tests/conftest.py
else
echo "### "
fi
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
Expand Down

0 comments on commit 4b94c62

Please sign in to comment.