Skip to content

Commit

Permalink
ci: ANSYS_DPF_PATH approach
Browse files Browse the repository at this point in the history
  • Loading branch information
moe-ad committed Jan 27, 2025
1 parent 58f66f2 commit 1893410
Showing 1 changed file with 34 additions and 16 deletions.
50 changes: 34 additions & 16 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,11 @@ jobs:
standalone_suffix: ${{ inputs.standalone_suffix }}
ANSYS_VERSION : ${{inputs.ANSYS_VERSION}}

- name: "Set ANSYS_DPF_PATH environment variable"
shell: bash
run: |
echo ANSYS_DPF_PATH=dpf-standalone/v${{inputs.ANSYS_VERSION}}/ansys/dpf/* >> $GITHUB_ENV
- name: "Check licences of packages"
uses: ansys/pydpf-actions/[email protected]

Expand Down Expand Up @@ -229,10 +234,11 @@ 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 "VIRTUALENV_SYSTEM_SITE_PACKAGES=true" >> $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"
shell: bash
Expand All @@ -247,7 +253,8 @@ jobs:
- name: "Test API"
shell: bash
run: |
tox -e test-api --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-api.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -259,7 +266,8 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-launcher --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-launcher.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -271,7 +279,8 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-server --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-server.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -283,7 +292,8 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-local_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-local_server.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -295,7 +305,8 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-multi_server --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-multi_server.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -307,7 +318,8 @@ jobs:
max_attempts: 3
shell: bash
command: |
tox -e test-remote_workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-remote_workflow.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -316,7 +328,8 @@ jobs:
shell: bash
working-directory: test_remote_operator
run: |
tox -e test-remote_operator --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-remote_operator.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -329,7 +342,8 @@ jobs:
retry_wait_seconds: 15
shell: bash
command: |
tox -e test-workflow --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-workflow.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -341,15 +355,17 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-service --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-service.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]

- name: "Test API Entry"
shell: bash
run: |
tox -e test-api_entry --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-api_entry.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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

# - name: "Kill all servers"
Expand All @@ -362,7 +378,8 @@ jobs:
max_attempts: 2
shell: bash
command: |
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}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand All @@ -374,7 +391,8 @@ jobs:
max_attempts: 2
shell: bash
command: |
tox -e test-operators --installpkg dist/${{ steps.wheel.outputs.wheel_name }} -x testenv:test-operators.deps+='dpf-standalone/v${{inputs.ANSYS_VERSION}}'
tox -e 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"
# uses: ansys/pydpf-actions/[email protected]
Expand Down

0 comments on commit 1893410

Please sign in to comment.