-
Notifications
You must be signed in to change notification settings - Fork 53
68 lines (61 loc) · 2.72 KB
/
integration_tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: Integration tests
on:
pull_request:
paths:
- ".github/workflows/integration_tests.yml"
- "nxdrive/**/*.py"
- "tests/integration/**/*.py"
- "tools/deps/*.txt"
push:
branches: [master]
paths:
- "nxdrive/**/*.py"
- "tests/integration/**/*.py"
env:
FREEZE_ONLY: 1
jobs:
integration-tests-windows:
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
lts_environment: [ ["https://drive-2021.beta.nuxeocloud.com/nuxeo", "2021", "NXDRIVE_TEST_USERNAME", "NXDRIVE_TEST_PASSWORD"], ["https://drive-2023.beta.nuxeocloud.com/nuxeo", "2023", "NXDRIVE_2023_TEST_USERNAME", "NXDRIVE_2023_TEST_PASSWORD"] ]
env:
NXDRIVE_TEST_NUXEO_URL: ${{ matrix.lts_environment[0] }}
NXDRIVE_TEST_USERNAME: ${{ secrets[matrix.lts_environment[2]] }}
NXDRIVE_TEST_PASSWORD: ${{ secrets[matrix.lts_environment[3]] }}
name: integration-tests-windows(LTS ${{ matrix.lts_environment[1] }})
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9 # XXX_PYTHON
architecture: "x86"
- uses: actions/cache@v4
with:
path: ~\AppData\Local\pip\Cache
key: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements.txt', 'tools/deps/requirements-test.txt', 'tools/deps/requirements-dev.txt', 'tools/deps/requirements-tox.txt') }}
restore-keys: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements.txt', 'tools/deps/requirements-test.txt', 'tools/deps/requirements-dev.txt', 'tools/deps/requirements-tox.txt') }}
# Cannot be used for now: OSError: [WinError 193] %1 is not a valid Win32 application
# - uses: actions/cache@v4
# with:
# path: .tox
# key: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }}
# restore-keys: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }}
- name: Freeze the application
run: |
powershell Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope LocalMachine
powershell ".\\tools\\windows\\deploy_ci_agent.ps1" -install_release
powershell ".\\tools\\windows\\deploy_ci_agent.ps1" -build
- name: Install tox
run: python -m pip install -r tools/deps/requirements-tox.txt
- name: Integration tests
run: tox -e integration
- name: Upload coverage to Codecov
if: ${{ success() }} || ${{ failure() }}
uses: codecov/codecov-action@v3.1.5
with:
files: ./coverage.xml
flags: integration
env_vars: OS,PYTHON