|
1 | 1 | name: Test wheels |
2 | 2 |
|
3 | 3 | on: |
| 4 | + push: |
| 5 | + paths: |
| 6 | + - '.github/workflows/test-wheels.yml' |
4 | 7 | workflow_call: |
5 | 8 | inputs: |
6 | 9 | matrix: |
7 | 10 | type: string |
8 | | - required: true |
| 11 | + required: false |
| 12 | + wheel_source: |
| 13 | + type: string |
| 14 | + required: false |
| 15 | + workflow_dispatch: |
| 16 | + inputs: |
| 17 | + wheel_source: |
| 18 | + type: string |
| 19 | + required: false |
| 20 | + schedule: |
| 21 | + - cron: '5 6 * * *' |
9 | 22 |
|
10 | 23 | jobs: |
| 24 | + maybe-generate-matrix: |
| 25 | + if: inputs.matrix == '' |
| 26 | + uses: ./.github/workflows/generate-matrix.yml |
| 27 | + |
11 | 28 | test-wheels: |
| 29 | + needs: [maybe-generate-matrix] |
12 | 30 | strategy: |
13 | 31 | fail-fast: false |
14 | | - matrix: ${{ fromJSON(inputs.matrix) }} |
| 32 | + matrix: ${{ fromJSON(inputs.matrix || needs.maybe-generate-matrix.outputs.test_matrix) }} |
15 | 33 | runs-on: ${{ matrix.os }} |
| 34 | + env: |
| 35 | + WHEEL_SOURCE: ${{ inputs.wheel_source || 'https://sumo.dlr.de/daily/ciwheels' }} |
16 | 36 |
|
17 | 37 | steps: |
18 | 38 | - name: Cloning SUMO |
@@ -46,11 +66,11 @@ jobs: |
46 | 66 | run: python -m pip install -r tools/req_ci.txt -r tools/requirements.txt |
47 | 67 |
|
48 | 68 | - name: Installing sumo wheels (macos / windows) |
49 | | - if: ${{ !startsWith(matrix.os, 'ubuntu') }} |
| 69 | + if: ${{ !startsWith(matrix.os, 'ubuntu') || inputs.wheel_source != 'python-wheels'}} |
50 | 70 | shell: bash |
51 | 71 | run: | |
52 | 72 | source testenv/*/activate |
53 | | - python -m pip install --no-index -f python-wheels eclipse_sumo |
| 73 | + python -m pip install --no-index -f $WHEEL_SOURCE eclipse_sumo |
54 | 74 | python -c "import sumo; print('SUMO_HOME=' + sumo.SUMO_HOME)" >> $GITHUB_ENV |
55 | 75 |
|
56 | 76 | - name: Installing sumo wheels (linux) |
@@ -97,11 +117,11 @@ jobs: |
97 | 117 | python -m pip install texttest |
98 | 118 |
|
99 | 119 | - name: Installing libsumo wheels (macos / windows) |
100 | | - if: ${{ !startsWith(matrix.os, 'ubuntu') }} |
| 120 | + if: ${{ !startsWith(matrix.os, 'ubuntu') || inputs.wheel_source != 'python-wheels' }} |
101 | 121 | shell: bash |
102 | 122 | run: | |
103 | 123 | if [[ "${{ matrix.os }}" != "windows-latest" ]]; then source libsumo_testenv/*/activate; fi |
104 | | - python -m pip install --no-index -f python-wheels libsumo |
| 124 | + python -m pip install --no-index -f $WHEEL_SOURCE libsumo |
105 | 125 |
|
106 | 126 | - name: Installing libsumo wheels (linux) |
107 | 127 | if: ${{ startsWith(matrix.os, 'ubuntu') }} |
|
0 commit comments