Skip to content

Commit 3f5ab78

Browse files
authored
Add more tests (#71)
1 parent ca3b9ac commit 3f5ab78

File tree

5 files changed

+2356
-758
lines changed

5 files changed

+2356
-758
lines changed

.github/workflows/test.yml

+59-7
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
default:
1212
strategy:
1313
matrix:
14-
os: [ubuntu-latest, macos-latest, windows-latest]
14+
os: [ubuntu-latest, macos-latest, windows-latest, macos-14]
1515
cache: [true, false]
1616
runs-on: ${{ matrix.os }}
1717
name: default ${{ matrix.cache == true && 'with' || 'without' }} cache (${{ matrix.os }})
@@ -61,12 +61,12 @@ jobs:
6161
custom-pixi-version:
6262
strategy:
6363
matrix:
64-
os: [ubuntu-latest, macos-latest, windows-latest]
64+
os: [ubuntu-latest, macos-latest, windows-latest, macos-14]
6565
runs-on: ${{ matrix.os }}
6666
steps:
6767
- uses: actions/checkout@v4
6868
- name: Move pixi.toml
69-
run: mv test/default/* .
69+
run: mv test/old-pixi-lockfiles/* .
7070
- uses: ./
7171
with:
7272
cache: false
@@ -75,6 +75,58 @@ jobs:
7575
locked: false
7676
- run: pixi --version | grep -q "pixi 0.1.0"
7777

78+
old-lockfile:
79+
strategy:
80+
matrix:
81+
os: [ubuntu-latest, macos-latest, windows-latest]
82+
locked: [true, false]
83+
runs-on: ${{ matrix.os }}
84+
steps:
85+
- uses: actions/checkout@v4
86+
- name: Move pixi.toml
87+
run: mv test/old-pixi-lockfiles/* .
88+
- uses: ./
89+
with:
90+
pixi-version: latest
91+
cache: false
92+
locked: ${{ matrix.locked }}
93+
- if: matrix.os == 'windows-latest'
94+
run: choco install yq
95+
# assert that the lockfile wasn't updated
96+
- run: test "$(yq '.version' pixi.lock)" = 1
97+
98+
install-path:
99+
strategy:
100+
matrix:
101+
os: [ubuntu-latest, macos-latest, windows-latest, macos-14]
102+
runs-on: ${{ matrix.os }}
103+
steps:
104+
- uses: actions/checkout@v4
105+
- uses: ./
106+
with:
107+
run-install: false
108+
- run: test "$(which pixi)" = "$HOME/.pixi/bin/pixi"
109+
shell: bash
110+
111+
global-install:
112+
strategy:
113+
matrix:
114+
os: [ubuntu-latest, macos-latest, windows-latest, macos-14]
115+
runs-on: ${{ matrix.os }}
116+
steps:
117+
- uses: actions/checkout@v4
118+
- uses: ./
119+
with:
120+
run-install: false
121+
- run: pixi global install cowpy
122+
- run: |
123+
pixi global list 2>&1 | grep cowpy
124+
cowpy hello world
125+
test "$(which cowpy)" = "$HOME/.pixi/bin/cowpy"
126+
if: matrix.os != 'windows-latest'
127+
- run: cowpy hello world
128+
if: matrix.os == 'windows-latest'
129+
78130
frozen:
79131
strategy:
80132
matrix:
@@ -110,7 +162,7 @@ jobs:
110162
steps:
111163
- uses: actions/checkout@v4
112164
- name: Move pixi.toml
113-
run: mv test/default/* .
165+
run: mv test/old-pixi-lockfiles/* .
114166
- uses: ./
115167
with:
116168
cache: false
@@ -393,7 +445,7 @@ jobs:
393445
strategy:
394446
fail-fast: false
395447
matrix:
396-
os: [windows-latest, ubuntu-latest, macos-latest]
448+
os: [windows-latest, ubuntu-latest, macos-latest, macos-14]
397449
steps:
398450
- uses: actions/checkout@v4
399451
- name: Move pixi files
@@ -418,7 +470,7 @@ jobs:
418470
strategy:
419471
fail-fast: false
420472
matrix:
421-
os: [windows-latest, ubuntu-latest, macos-latest]
473+
os: [windows-latest, ubuntu-latest, macos-latest, macos-14]
422474
steps:
423475
- uses: actions/checkout@v4
424476
- name: Move pixi files
@@ -442,7 +494,7 @@ jobs:
442494
strategy:
443495
fail-fast: false
444496
matrix:
445-
os: [windows-latest, ubuntu-latest, macos-latest]
497+
os: [windows-latest, ubuntu-latest, macos-latest, macos-14]
446498
steps:
447499
- uses: actions/checkout@v4
448500
- name: Move pixi files

0 commit comments

Comments
 (0)