Move control logic to main workflow, remove inputs
This commit is contained in:
		
							
								
								
									
										8
									
								
								.github/workflows/ci.yaml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										8
									
								
								.github/workflows/ci.yaml
									
									
									
									
										vendored
									
									
								
							| @@ -91,17 +91,13 @@ jobs: | |||||||
|     needs: [ prechecks, changes ] |     needs: [ prechecks, changes ] | ||||||
|     uses: ./.github/workflows/bootstrap.yml |     uses: ./.github/workflows/bootstrap.yml | ||||||
|   unit-tests: |   unit-tests: | ||||||
|     if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.core == 'true' }} |     if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.core == 'false' }} | ||||||
|     needs: [ prechecks, changes ] |     needs: [ prechecks, changes ] | ||||||
|     uses: ./.github/workflows/unit_tests.yaml |     uses: ./.github/workflows/unit_tests.yaml | ||||||
|     with: |  | ||||||
|       core: ${{ needs.changes.outputs.core }} |  | ||||||
|   windows: |   windows: | ||||||
|     if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.core == 'true' }} |     if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.core == 'false' }} | ||||||
|     needs: [ prechecks ] |     needs: [ prechecks ] | ||||||
|     uses: ./.github/workflows/windows_python.yml |     uses: ./.github/workflows/windows_python.yml | ||||||
|     with: |  | ||||||
|       core: ${{ needs.changes.outputs.core }} |  | ||||||
|   all: |   all: | ||||||
|     needs: [ windows, unit-tests, bootstrap, audit-ancient-python ] |     needs: [ windows, unit-tests, bootstrap, audit-ancient-python ] | ||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|   | |||||||
							
								
								
									
										17
									
								
								.github/workflows/unit_tests.yaml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										17
									
								
								.github/workflows/unit_tests.yaml
									
									
									
									
										vendored
									
									
								
							| @@ -2,17 +2,7 @@ name: unit tests | |||||||
|  |  | ||||||
| on: | on: | ||||||
|   workflow_dispatch: |   workflow_dispatch: | ||||||
|     inputs: |  | ||||||
|       core: |  | ||||||
|         description: "If false the test is skipped" |  | ||||||
|         required: true |  | ||||||
|         type: string |  | ||||||
|         default: "true" |  | ||||||
|   workflow_call: |   workflow_call: | ||||||
|     inputs: |  | ||||||
|       core: |  | ||||||
|         required: true |  | ||||||
|         type: string |  | ||||||
|  |  | ||||||
| concurrency: | concurrency: | ||||||
|   group: unit_tests-${{github.ref}}-${{github.event.pull_request.number || github.run_number}} |   group: unit_tests-${{github.ref}}-${{github.event.pull_request.number || github.run_number}} | ||||||
| @@ -21,7 +11,6 @@ concurrency: | |||||||
| jobs: | jobs: | ||||||
|   # Run unit tests with different configurations on linux |   # Run unit tests with different configurations on linux | ||||||
|   ubuntu: |   ubuntu: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|     strategy: |     strategy: | ||||||
|       matrix: |       matrix: | ||||||
| @@ -123,11 +112,10 @@ jobs: | |||||||
|           . .github/workflows/setup_git.sh |           . .github/workflows/setup_git.sh | ||||||
|     - name: Run shell tests |     - name: Run shell tests | ||||||
|       env: |       env: | ||||||
|           COVERAGE: ${{ inputs.core }} |           COVERAGE: true | ||||||
|       run: | |       run: | | ||||||
|           share/spack/qa/run-shell-tests |           share/spack/qa/run-shell-tests | ||||||
|     - uses: codecov/codecov-action@81cd2dc8148241f03f5839d295e000b8f761e378 # @v2.1.0 |     - uses: codecov/codecov-action@81cd2dc8148241f03f5839d295e000b8f761e378 # @v2.1.0 | ||||||
|       if: ${{ inputs.core == 'true' }} |  | ||||||
|       with: |       with: | ||||||
|         flags: shelltests,linux |         flags: shelltests,linux | ||||||
|  |  | ||||||
| @@ -135,7 +123,6 @@ jobs: | |||||||
|   # only on PRs modifying core Spack |   # only on PRs modifying core Spack | ||||||
|   rhel8-platform-python: |   rhel8-platform-python: | ||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     container: registry.access.redhat.com/ubi8/ubi |     container: registry.access.redhat.com/ubi8/ubi | ||||||
|     steps: |     steps: | ||||||
|     - name: Install dependencies |     - name: Install dependencies | ||||||
| @@ -159,7 +146,6 @@ jobs: | |||||||
|           spack unit-test -k 'not cvs and not svn and not hg' -x --verbose |           spack unit-test -k 'not cvs and not svn and not hg' -x --verbose | ||||||
|   # Test for the clingo based solver (using clingo-cffi) |   # Test for the clingo based solver (using clingo-cffi) | ||||||
|   clingo-cffi: |   clingo-cffi: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|     steps: |     steps: | ||||||
|     - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # @v2 |     - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # @v2 | ||||||
| @@ -196,7 +182,6 @@ jobs: | |||||||
|         flags: unittests,linux,clingo |         flags: unittests,linux,clingo | ||||||
|   # Run unit tests on MacOS |   # Run unit tests on MacOS | ||||||
|   macos: |   macos: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     runs-on: macos-latest |     runs-on: macos-latest | ||||||
|     strategy: |     strategy: | ||||||
|       matrix: |       matrix: | ||||||
|   | |||||||
							
								
								
									
										8
									
								
								.github/workflows/windows_python.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										8
									
								
								.github/workflows/windows_python.yml
									
									
									
									
										vendored
									
									
								
							| @@ -2,10 +2,6 @@ name: windows | |||||||
|  |  | ||||||
| on: | on: | ||||||
|   workflow_call: |   workflow_call: | ||||||
|     inputs: |  | ||||||
|       core: |  | ||||||
|         type: string |  | ||||||
|         required: true |  | ||||||
|  |  | ||||||
| concurrency: | concurrency: | ||||||
|   group: windows-${{github.ref}}-${{github.event.pull_request.number || github.run_number}} |   group: windows-${{github.ref}}-${{github.event.pull_request.number || github.run_number}} | ||||||
| @@ -17,7 +13,6 @@ defaults: | |||||||
|      powershell Invoke-Expression -Command ".\share\spack\qa\windows_test_setup.ps1"; {0} |      powershell Invoke-Expression -Command ".\share\spack\qa\windows_test_setup.ps1"; {0} | ||||||
| jobs: | jobs: | ||||||
|   unit-tests: |   unit-tests: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     runs-on: windows-latest |     runs-on: windows-latest | ||||||
|     steps: |     steps: | ||||||
|     - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b |     - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b | ||||||
| @@ -37,7 +32,6 @@ jobs: | |||||||
|         echo F|xcopy .\spack\share\spack\qa\configuration\windows_config.yaml $env:USERPROFILE\.spack\windows\config.yaml |         echo F|xcopy .\spack\share\spack\qa\configuration\windows_config.yaml $env:USERPROFILE\.spack\windows\config.yaml | ||||||
|         spack unit-test --verbose --ignore=lib/spack/spack/test/cmd |         spack unit-test --verbose --ignore=lib/spack/spack/test/cmd | ||||||
|   unit-tests-cmd: |   unit-tests-cmd: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     runs-on: windows-latest |     runs-on: windows-latest | ||||||
|     steps: |     steps: | ||||||
|     - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b |     - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b | ||||||
| @@ -76,7 +70,6 @@ jobs: | |||||||
|         spack external find ninja |         spack external find ninja | ||||||
|         spack install abseil-cpp |         spack install abseil-cpp | ||||||
|   make-installer: |   make-installer: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     runs-on: windows-latest |     runs-on: windows-latest | ||||||
|     steps: |     steps: | ||||||
|     - name: Disable Windows Symlinks |     - name: Disable Windows Symlinks | ||||||
| @@ -112,7 +105,6 @@ jobs: | |||||||
|         name: Windows Spack Installer |         name: Windows Spack Installer | ||||||
|         path: ${{ env.installer_root}}\pkg\Spack.msi |         path: ${{ env.installer_root}}\pkg\Spack.msi | ||||||
|   execute-installer: |   execute-installer: | ||||||
|     if: ${{ inputs.core == 'false' }} |  | ||||||
|     needs: make-installer |     needs: make-installer | ||||||
|     runs-on: windows-latest |     runs-on: windows-latest | ||||||
|     defaults: |     defaults: | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Massimiliano Culpo
					Massimiliano Culpo