diff --git a/.gitea/workflows/Publish Module.yaml b/.gitea/workflows/Publish Module.yaml index 718bee0..e6e67b9 100644 --- a/.gitea/workflows/Publish Module.yaml +++ b/.gitea/workflows/Publish Module.yaml @@ -8,7 +8,26 @@ on: workflow_dispatch: jobs: + test: + runs-on: ubuntu-22.04 + container: + image: catthehacker/ubuntu:pwsh-latest + + steps: + - name: Check out repository code + uses: actions/checkout@v4 + + - name: Run pester tests and verify all tests pass + shell: pwsh + run: | + + Write-Host "Changing to repository directory: ${{ github.workspace }}" + Set-Location -Path ${{ github.workspace }} + Write-Host "Running Pester tests" + Invoke-Pester -Path . -PassThru | Select-Object -ExpandProperty FailedCount | Should -Be 0 -ErrorAction stop + deploy: + needs: test runs-on: ubuntu-22.04 container: image: catthehacker/ubuntu:pwsh-latest