Action-Test - [ #] by @MariusStorhaug #918
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Action-Test | |
| run-name: 'Action-Test - [${{ github.event.pull_request.title }} #${{ github.event.pull_request.number }}] by @${{ github.actor }}' | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| schedule: | |
| - cron: '0 0 * * *' | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| permissions: | |
| contents: read | |
| pull-requests: read | |
| jobs: | |
| ActionTest1Simple: | |
| name: Action-Test - [1-Simple] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [1-Simple] | |
| uses: ./ | |
| id: action-test | |
| with: | |
| WorkingDirectory: tests/1-Simple | |
| Debug: true | |
| Verbose: true | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest1SimpleFile: | |
| name: Action-Test - [1-Simple-File] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [1-Simple-File] | |
| uses: ./ | |
| id: action-test | |
| with: | |
| WorkingDirectory: tests/1-Simple | |
| Path: Emoji.Tests.ps1 | |
| Run_Path: Emoji | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest1SimpleFailure: | |
| name: Action-Test - [1-Simple-Failure] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [1-Simple-Failure] | |
| uses: ./ | |
| id: action-test | |
| continue-on-error: true | |
| with: | |
| WorkingDirectory: tests/1-Simple-Failure | |
| StepSummary_Mode: Full | |
| StepSummary_ShowTestOverview: true | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest1SimpleFailureOnlyFailedSummary: | |
| name: Action-Test - [1-Simple-Failure-OnlyFailedSummary] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [1-Simple-Failure] | |
| uses: ./ | |
| id: action-test | |
| continue-on-error: true | |
| with: | |
| WorkingDirectory: tests/1-Simple-Failure | |
| TestResult_TestSuiteName: 1-Simple-Failure | |
| StepSummary_ShowConfiguration: true | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest1SimpleExecutionFailure: | |
| name: Action-Test - [1-Simple-ExecutionFailure] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [1-Simple-ExecutionFailure] | |
| uses: ./ | |
| id: action-test | |
| continue-on-error: true | |
| with: | |
| WorkingDirectory: tests/1-Simple-ExecutionFailure | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest2Standard: | |
| name: Action-Test - [2-Standard] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [2-Standard] | |
| uses: ./ | |
| id: action-test | |
| env: | |
| RUNNER_OS: ${{ runner.os }} | |
| with: | |
| WorkingDirectory: tests/2-Standard | |
| Output_CIFormat: GithubActions | |
| Prescript: | | |
| Write-Host "This is a prescript" | |
| Write-Host "We are running on $env:RUNNER_OS" | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest2StandardPrescriptFile: | |
| name: Action-Test - [2-Standard-PrescriptFile] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [2-Standard-PrescriptFile] | |
| uses: ./ | |
| id: action-test | |
| with: | |
| WorkingDirectory: tests/2-Standard | |
| Output_CIFormat: GithubActions | |
| Prescript: ../Prescript.ps1 | |
| TestResult_TestSuiteName: 2-Standard-PrescriptFile | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest2StandardNoSummary: | |
| name: Action-Test - [2-Standard-NoSummary] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [2-Standard-NoSummary] | |
| uses: ./ | |
| id: action-test | |
| with: | |
| WorkingDirectory: tests/2-Standard | |
| Output_CIFormat: GithubActions | |
| TestResult_TestSuiteName: 2-Standard-NoSummary | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| ActionTest3Advanced: | |
| name: Action-Test - [3-Advanced] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| Outcome: ${{ steps.action-test.outcome }} | |
| Conclusion: ${{ steps.action-test.conclusion }} | |
| Executed: ${{ steps.action-test.outputs.Executed }} | |
| Result: ${{ steps.action-test.outputs.Result }} | |
| steps: | |
| # Need to check out as part of the test, as its a local action | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Action-Test [3-Advanced] | |
| uses: ./ | |
| id: action-test | |
| with: | |
| Path: Pester.Configuration.ps1 | |
| WorkingDirectory: tests/3-Advanced | |
| StepSummary_Mode: None | |
| - name: Status | |
| shell: pwsh | |
| env: | |
| OUTCOME: ${{ steps.action-test.outcome }} | |
| CONCLUSION: ${{ steps.action-test.conclusion }} | |
| run: tests/Show-Status.ps1 | |
| CatchJob: | |
| name: Catch Job - Aggregate Status | |
| needs: | |
| - ActionTest1Simple | |
| - ActionTest1SimpleFile | |
| - ActionTest1SimpleFailure | |
| - ActionTest1SimpleFailureOnlyFailedSummary | |
| - ActionTest1SimpleExecutionFailure | |
| - ActionTest2Standard | |
| - ActionTest2StandardPrescriptFile | |
| - ActionTest2StandardNoSummary | |
| - ActionTest3Advanced | |
| if: always() | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Display Aggregated Results as a Table | |
| uses: PSModule/GitHub-Script@0097f3bbe3f413f3b577b9bcc600727b0ca3201a # v1.7.10 | |
| env: | |
| ACTIONTEST1SIMPLE_OUTCOME: ${{ needs.ActionTest1Simple.outputs.Outcome }} | |
| ACTIONTEST1SIMPLE_CONCLUSION: ${{ needs.ActionTest1Simple.outputs.Conclusion }} | |
| ACTIONTEST1SIMPLE_EXECUTED: ${{ needs.ActionTest1Simple.outputs.Executed }} | |
| ACTIONTEST1SIMPLE_RESULT: ${{ needs.ActionTest1Simple.outputs.Result }} | |
| ACTIONTEST1SIMPLEFILE_OUTCOME: ${{ needs.ActionTest1SimpleFile.outputs.Outcome }} | |
| ACTIONTEST1SIMPLEFILE_CONCLUSION: ${{ needs.ActionTest1SimpleFile.outputs.Conclusion }} | |
| ACTIONTEST1SIMPLEFILE_EXECUTED: ${{ needs.ActionTest1SimpleFile.outputs.Executed }} | |
| ACTIONTEST1SIMPLEFILE_RESULT: ${{ needs.ActionTest1SimpleFile.outputs.Result }} | |
| ACTIONTEST1SIMPLEFAILURE_OUTCOME: ${{ needs.ActionTest1SimpleFailure.outputs.Outcome }} | |
| ACTIONTEST1SIMPLEFAILURE_CONCLUSION: ${{ needs.ActionTest1SimpleFailure.outputs.Conclusion }} | |
| ACTIONTEST1SIMPLEFAILURE_EXECUTED: ${{ needs.ActionTest1SimpleFailure.outputs.Executed }} | |
| ACTIONTEST1SIMPLEFAILURE_RESULT: ${{ needs.ActionTest1SimpleFailure.outputs.Result }} | |
| ACTIONTEST1SIMPLEFAILUREONLYFAILEDSUMMARY_OUTCOME: ${{ needs.ActionTest1SimpleFailureOnlyFailedSummary.outputs.Outcome }} | |
| ACTIONTEST1SIMPLEFAILUREONLYFAILEDSUMMARY_CONCLUSION: ${{ needs.ActionTest1SimpleFailureOnlyFailedSummary.outputs.Conclusion }} | |
| ACTIONTEST1SIMPLEFAILUREONLYFAILEDSUMMARY_EXECUTED: ${{ needs.ActionTest1SimpleFailureOnlyFailedSummary.outputs.Executed }} | |
| ACTIONTEST1SIMPLEFAILUREONLYFAILEDSUMMARY_RESULT: ${{ needs.ActionTest1SimpleFailureOnlyFailedSummary.outputs.Result }} | |
| ACTIONTEST1SIMPLEEXECUTIONFAILURE_OUTCOME: ${{ needs.ActionTest1SimpleExecutionFailure.outputs.Outcome }} | |
| ACTIONTEST1SIMPLEEXECUTIONFAILURE_CONCLUSION: ${{ needs.ActionTest1SimpleExecutionFailure.outputs.Conclusion }} | |
| ACTIONTEST1SIMPLEEXECUTIONFAILURE_EXECUTED: ${{ needs.ActionTest1SimpleExecutionFailure.outputs.Executed }} | |
| ACTIONTEST1SIMPLEEXECUTIONFAILURE_RESULT: ${{ needs.ActionTest1SimpleExecutionFailure.outputs.Result }} | |
| ACTIONTEST2STANDARD_OUTCOME: ${{ needs.ActionTest2Standard.outputs.Outcome }} | |
| ACTIONTEST2STANDARD_CONCLUSION: ${{ needs.ActionTest2Standard.outputs.Conclusion }} | |
| ACTIONTEST2STANDARD_EXECUTED: ${{ needs.ActionTest2Standard.outputs.Executed }} | |
| ACTIONTEST2STANDARD_RESULT: ${{ needs.ActionTest2Standard.outputs.Result }} | |
| ACTIONTEST2STANDARDPRESCRIPTFILE_OUTCOME: ${{ needs.ActionTest2StandardPrescriptFile.outputs.Outcome }} | |
| ACTIONTEST2STANDARDPRESCRIPTFILE_CONCLUSION: ${{ needs.ActionTest2StandardPrescriptFile.outputs.Conclusion }} | |
| ACTIONTEST2STANDARDPRESCRIPTFILE_EXECUTED: ${{ needs.ActionTest2StandardPrescriptFile.outputs.Executed }} | |
| ACTIONTEST2STANDARDPRESCRIPTFILE_RESULT: ${{ needs.ActionTest2StandardPrescriptFile.outputs.Result }} | |
| ACTIONTEST2STANDARDNOSUMMARY_OUTCOME: ${{ needs.ActionTest2StandardNoSummary.outputs.Outcome }} | |
| ACTIONTEST2STANDARDNOSUMMARY_CONCLUSION: ${{ needs.ActionTest2StandardNoSummary.outputs.Conclusion }} | |
| ACTIONTEST2STANDARDNOSUMMARY_EXECUTED: ${{ needs.ActionTest2StandardNoSummary.outputs.Executed }} | |
| ACTIONTEST2STANDARDNOSUMMARY_RESULT: ${{ needs.ActionTest2StandardNoSummary.outputs.Result }} | |
| ACTIONTEST3ADVANCED_OUTCOME: ${{ needs.ActionTest3Advanced.outputs.Outcome }} | |
| ACTIONTEST3ADVANCED_CONCLUSION: ${{ needs.ActionTest3Advanced.outputs.Conclusion }} | |
| ACTIONTEST3ADVANCED_EXECUTED: ${{ needs.ActionTest3Advanced.outputs.Executed }} | |
| ACTIONTEST3ADVANCED_RESULT: ${{ needs.ActionTest3Advanced.outputs.Result }} | |
| with: | |
| Script: tests/Test-ActionResults.ps1 |