Skip to content

Commit

Permalink
ci: another fix
Browse files Browse the repository at this point in the history
  • Loading branch information
moe-ad committed Jan 27, 2025
1 parent f55effd commit aa9edc0
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 18 deletions.
37 changes: 19 additions & 18 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,9 @@ jobs:
- name: "Set ANSYS_DPF_PATH environment variable"
shell: bash
run: |
export ANSYS_DPF_PATH=dpf-standalone/v${{inputs.ANSYS_VERSION}}/ansys/dpf/*
echo $ANSYS_DPF_PATH >> $GITHUB_ENV
ANSYS_DPF_PATH=$(echo dpf-standalone/v${{inputs.ANSYS_VERSION}}/ansys/dpf/*)
echo "ANSYS_DPF_PATH=$ANSYS_DPF_PATH" >> $GITHUB_ENV
# tree $ANSYS_DPF_PATH

- name: "Check licences of packages"
uses: ansys/pydpf-actions/[email protected]
Expand Down Expand Up @@ -235,10 +236,10 @@ jobs:
# echo "COVERAGE=--cov=ansys.dpf.${{env.MODULE}} --cov-report=xml --cov-report=html --log-level=ERROR --cov-append" >> $GITHUB_ENV
# echo "RERUNS=--reruns 2 --reruns-delay 1" >> $GITHUB_ENV

- name: "Set environment variable to allow test targets access DPF server installation"
shell: bash
run: |
echo "ANSYS_DPF_PATH=dpf-standalone/v${{inputs.ANSYS_VERSION}}" >> $GITHUB_ENV
# - name: "Set environment variable to allow test targets access DPF server installation"
# shell: bash
# run: |
# echo "ANSYS_DPF_PATH=dpf-standalone/v${{inputs.ANSYS_VERSION}}" >> $GITHUB_ENV
# echo "VIRTUALENV_SYSTEM_SITE_PACKAGES=true" >> $GITHUB_ENV

- name: "Organize test files"
Expand All @@ -254,7 +255,7 @@ jobs:
- name: "Test API"
shell: bash
run: |
tox -e test-api --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-api --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-api --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-api.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -267,7 +268,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-launcher --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-launcher --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-launcher --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-launcher.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -280,7 +281,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-server --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-server --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-server --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-server.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -293,7 +294,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-local_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-local_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-local_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-local_server.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -306,7 +307,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-multi_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-multi_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-multi_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-multi_server.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -319,7 +320,7 @@ jobs:
max_attempts: 3
shell: bash
command: |
tox -e test-remote_workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-remote_workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-remote_workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-remote_workflow.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -329,7 +330,7 @@ jobs:
shell: bash
working-directory: test_remote_operator
run: |
tox -e test-remote_operator --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-remote_operator --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-remote_operator --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-remote_operator.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -343,7 +344,7 @@ jobs:
retry_wait_seconds: 15
shell: bash
command: |
tox -e test-workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-workflow.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -356,7 +357,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-service --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-service --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-service --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-service.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -365,7 +366,7 @@ jobs:
- name: "Test API Entry"
shell: bash
run: |
tox -e test-api_entry --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-api_entry --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-api_entry --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-api_entry.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
timeout-minutes: 30

Expand All @@ -379,7 +380,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-custom_type_field --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-custom_type_field --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-custom_type_field --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-custom_type_field.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand All @@ -392,7 +393,7 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-operators --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
tox -e kill-servers,test-operators --installpkg dist/${{ steps.wheel.outputs.wheel_name }}
# tox -e test-operators --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-operators.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'

# - name: "Kill all servers"
Expand Down
6 changes: 6 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ pass_env =
AWP_ROOT*
ANSYS_DPF_PATH
VIRTUALENV_SYSTEM_SITE_PACKAGES
*

[testenv:build-wheel]
description = Environment for custom build of package wheels
Expand Down Expand Up @@ -121,7 +122,12 @@ setenv =
deps =
-r requirements/requirements_test.txt

allowlist_externals = *

commands =
# Ensure vtk compatibility
python -m pip uninstall --yes vtk
python -m pip install --extra-index-url https://wheels.vtk.org vtk-osmesa==9.2.20230527.dev0
python -m pytest {env:PYTEST_PYTHON_FILES} {env:DEBUG} {env:COVERAGE} {env:RERUNS} {env:JUNITXML}

[testenv:doc-{clean,links,html}]
Expand Down

0 comments on commit aa9edc0

Please sign in to comment.