File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -93,11 +93,14 @@ runs:
9393 shell : powershell
9494 - name : Run
9595 run : >-
96+ $eventPath = Split-Path -Path "${env:GITHUB_EVENT_PATH}" -Parent;
97+
9698 docker run
9799 ${{ steps.settings.outputs.default_environment_variables }}
98100 ${{ steps.settings.outputs.extra_args }}
99- --rm
101+ --rm
100102 --memory=${{ inputs.memory }}
103+ -v ${eventPath}:${eventPath}
101104 -v ${{ steps.settings.outputs.workspace_path }}:${{ steps.settings.outputs.mapping_path }}
102105 -w ${{ steps.settings.outputs.work_path }}
103106 ${{ inputs.image }}
Original file line number Diff line number Diff line change @@ -13,4 +13,10 @@ Describe "run_default" {
1313 $testfile | Should - Exist
1414 }
1515 }
16+
17+ Context " default GitHub Action paths should be available" {
18+ It " GITHUB_EVENT_PATH should exist" {
19+ " $env: GITHUB_EVENT_PATH " | Should - Exist
20+ }
21+ }
1622}
Original file line number Diff line number Diff line change @@ -8,14 +8,17 @@ if (-not(Test-Path -Path $testPath -PathType Leaf))
88 exit 1 ;
99}
1010
11- # using scoop to install pester
12- mkdir C:\TMP;
13- powershell.exe - ExecutionPolicy RemoteSigned ` Invoke-WebRequest ' https://get.scoop.sh' - outfile C:\TMP\install.ps1;
14- C:\TMP\install.ps1 - RunAsAdmin;
15- scoop install pester;
11+ Install-PackageProvider NuGet - Force;
12+ If ($? -ne " True" ) { Throw };
13+ Install-Module - Force - SkipPublisherCheck Pester;
14+ If ($? -ne " True" ) { Throw };
1615
1716$config = New-PesterConfiguration ;
17+ If ($? -ne " True" ) { Throw };
1818$config.Run.Exit = $true ;
19+ If ($? -ne " True" ) { Throw };
1920$config.Run.Path = " $testPath " ;
21+ If ($? -ne " True" ) { Throw };
2022
2123Invoke-Pester - Configuration $config ;
24+ If ($? -ne " True" ) { Throw };
You can’t perform that action at this time.
0 commit comments