Refactor and enhance GitHub Actions workflow and documentation #11
Workflow file for this run
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: Test | |
| on: | |
| push: | |
| branches: ["main"] | |
| paths: | |
| - "Module/**" | |
| - "Predictor/**" | |
| - "Build.ps1" | |
| pull_request: | |
| branches: ["main"] | |
| jobs: | |
| test: | |
| name: Pester test (${{ matrix.os }}) | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, windows-latest] | |
| steps: | |
| - name: Checkout Repository Code | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 1 # Fetch only the latest commit to speed up the checkout process | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v5 | |
| with: | |
| dotnet-version: 8.0.x | |
| - name: Build Module | |
| shell: pwsh | |
| run: ./Build.ps1 -Configuration Release | |
| - name: Run Tests | |
| shell: pwsh | |
| run: | | |
| Import-Module ./Module/PSFavorite.psd1 -Force | |
| Invoke-Pester -Path ./Module/Tests -Output Detailed -PassThru |