File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : ' test-cache-windows'
2+ on :
3+ pull_request :
4+ push :
5+ branches :
6+ - main
7+
8+ concurrency :
9+ group : ${{ github.workflow }}-${{ github.ref }}
10+ cancel-in-progress : true
11+
12+ jobs :
13+ test-setup-cache :
14+ runs-on : ${{ matrix.os }}
15+ strategy :
16+ matrix :
17+ os : [windows-latest]
18+ steps :
19+ - uses : actions/checkout@v4
20+ - name : Setup with cache
21+ uses : ./
22+ with :
23+ enable-cache : true
24+ working-directory : __tests__\fixtures\rye-project
25+ cache-prefix : ${{ github.run_id }}-${{ github.run_attempt }}
26+ - run : rye sync
27+ working-directory : __tests__\fixtures\rye-project
28+ test-restore-cache :
29+ runs-on : ${{ matrix.os }}
30+ strategy :
31+ matrix :
32+ os : [windows-latest]
33+ needs : test-setup-cache
34+ steps :
35+ - uses : actions/checkout@v4
36+ - name : Restore with cache
37+ id : restore
38+ uses : ./
39+ with :
40+ enable-cache : true
41+ working-directory : __tests__\fixtures\rye-project
42+ cache-prefix : ${{ github.run_id }}-${{ github.run_attempt }}
43+ - name : Cache was hit
44+ run : |
45+ if ($env:CACHE_HIT -ne "true") {
46+ exit 1
47+ }
48+ env :
49+ CACHE_HIT : ${{ steps.restore.outputs.cache-hit }}
50+ - run : rye sync
51+ working-directory : __tests__\fixtures\rye-project
Original file line number Diff line number Diff line change 1+ name : ' test-latest-windows'
2+ on :
3+ pull_request :
4+ push :
5+ branches :
6+ - main
7+
8+ concurrency :
9+ group : ${{ github.workflow }}-${{ github.ref }}
10+ cancel-in-progress : true
11+
12+ jobs :
13+ test-latest :
14+ runs-on : windows-latest
15+ steps :
16+ - uses : actions/checkout@v4
17+ - name : Should not be on path
18+ run : |
19+ if (!(Get-Command -Name "rye" -ErrorAction SilentlyContinue)) {
20+ exit 0
21+ } else {
22+ exit 1
23+ }
24+ - name : Setup rye
25+ uses : ./
26+ with :
27+ version : latest
28+ working-directory : __tests__\fixtures\rye-project
29+ github-token : ${{ secrets.GITHUB_TOKEN }}
30+ - run : rye sync
31+ working-directory : __tests__\fixtures\rye-project
32+ - name : Rye path is not added to .profile
33+ run : |
34+ $env:Path -split ';' | ForEach-Object {
35+ if ($_ -eq "C:\path\to\rye") {
36+ exit 1
37+ }
38+ }
39+ exit 0
40+ test-latest-without-github-token :
41+ runs-on : windows-latest
42+ steps :
43+ - uses : actions/checkout@v4
44+ - name : Setup rye
45+ uses : ./
46+ with :
47+ version : latest
48+ - run : rye sync
49+ working-directory : __tests__\fixtures\rye-project
Original file line number Diff line number Diff line change 44 push :
55 branches :
66 - main
7- schedule :
8- - cron : " 0 0 * * *"
97
108concurrency :
119 group : ${{ github.workflow }}-${{ github.ref }}
You can’t perform that action at this time.
0 commit comments