Skip to content

Commit

Permalink
optimizing workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Maksim Gelbakhiani committed Jan 23, 2024
1 parent ce29d88 commit 68f1157
Showing 1 changed file with 7 additions and 25 deletions.
32 changes: 7 additions & 25 deletions .github/workflows/system-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,30 +199,29 @@ jobs:

################################################################
- name: Run Sanity tests for pull requests
env:
ALLURE_RESULTS_DIR: ${{ github.workspace }}/allure-results
# env:
# ALLURE_RESULTS_DIR: ${{ github.workspace }}/allure-results
timeout-minutes: 120
if: github.event_name == 'pull_request'
run: |
source venv.local-pytest/bin/activate && pytest --show-capture=no -m "sanity" --alluredir="$ALLURE_RESULTS_DIR" pytest_tests/testsuites/services/s3_gate/test_s3_bucket.py
source venv.local-pytest/bin/activate && pytest --show-capture=no -m "sanity" --alluredir=${{ env.ALLURE_RESULTS_DIR }} pytest_tests/testsuites/services/s3_gate/test_s3_bucket.py
working-directory: neofs-testcases

- name: Run all tests for other events
env:
ALLURE_RESULTS_DIR: ${{ github.workspace }}/allure-results
# env:
# ALLURE_RESULTS_DIR: ${{ github.workspace }}/allure-results
timeout-minutes: 480
if: github.event_name != 'pull_request'
run: |
source venv.local-pytest/bin/activate && pytest --show-capture=no --alluredir="$ALLURE_RESULTS_DIR" pytest_tests/testsuites/services/s3_gate/test_s3_tagging.py
source venv.local-pytest/bin/activate && pytest --show-capture=no --alluredir=${{ env.ALLURE_RESULTS_DIR }} pytest_tests/testsuites/services/s3_gate/test_s3_tagging.py
working-directory: neofs-testcases

################################################################

- name: Publish to NeoFS
id: put_report
if: always() && steps.prepare_test_env.outcome == 'success'
# uses: nspcc-dev/gh-push-allure-report-to-neofs@master
uses: vvarg229/gh-push-allure-report-to-neofs@fix-debug
uses: nspcc-dev/gh-push-allure-report-to-neofs@master
with:
NEOFS_WALLET: ${{ secrets.TEST_RESULTS_WALLET }}
NEOFS_WALLET_PASSWORD: ${{ secrets.TEST_RESULTS_PASSWORD }}
Expand All @@ -249,22 +248,6 @@ jobs:
state: 'success'
sha: ${{github.event.pull_request.head.sha || github.sha}}
target_url: ${{ env.REPORT_NEOFS_URL }}


# - name: Post only docker logs
# id: post_dockers_logs
# if: always() && ( steps.prepare_test_env.outcome != 'success' || steps.put_report.outcome != 'success' )
# env:
# TEST_RESULTS_PASSWORD: ${{ secrets.TEST_RESULTS_PASSWORD }}
# TEST_RESULTS_NEOFS_NETWORK_DOMAIN: ${{ vars.TEST_RESULTS_NEOFS_NETWORK_DOMAIN }}
# TEST_RESULTS_CID: ${{ vars.TEST_RESULTS_CID }}
# run: |
# source venv.local-pytest/bin/activate && python ./tools/src/zip_dev_env_logs.py
# NEOFS_CLI_PASSWORD=$TEST_RESULTS_PASSWORD neofs-cli --rpc-endpoint st1.$TEST_RESULTS_NEOFS_NETWORK_DOMAIN:8080 \
# --wallet wallet.json object put --file containers_logs.zip --cid $TEST_RESULTS_CID --timeout 1200s \
# --expire-at $EXP_EPOCH \
# --attributes FilePath=$RUN_ID/data/containers_logs.zip,RunNumber=$RUN_ID,ContentType=application/zip
# working-directory: neofs-testcases

- name: Gather docker logs
id: gather_dockers_logs
Expand Down Expand Up @@ -295,7 +278,6 @@ jobs:
PATH_TO_FILES_DIR: ${{ env.DOCKER_LOGS }}
URL_PREFIX: ${{ env.RUN_ID }}/data


- name: Post the link to the docker logs
timeout-minutes: 60
if: always() && ( steps.post_dockers_logs.outcome == 'success' )
Expand Down

0 comments on commit 68f1157

Please sign in to comment.