Skip to content

Commit

Permalink
tweak actions matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
silverwind committed May 27, 2024
1 parent 0d0f684 commit 1200c57
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 7 deletions.
15 changes: 10 additions & 5 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,22 @@ jobs:
strategy:
fail-fast: false
matrix:
node: [18, 20, 22]
js: [[node, 18], [node, 20], [node,22], [bun,1]]
os: [ubuntu-latest, macos-latest, windows-latest]
bun: [latest]
runs-on: ${{matrix.os}}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{matrix.node}}
node-version: ${{matrix.js[1]}}
if: ${{matrix.js[0] == 'node'}}
- uses: oven-sh/setup-bun@v1
with:
bun-version: ${{matrix.bun}}
bun-version: ${{matrix.js[1]}}
if: ${{matrix.js[0] == 'bun'}}
- run: make lint test
- run: bun test
if: ${{matrix.js[0] == 'node'}}
- run: bun install && bunx vite build && chmod +x dist/index.js && bun test
if: ${{matrix.js[0] == 'bun'}}
env:
BUN: "true"
2 changes: 1 addition & 1 deletion index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ test("empty", async () => {
expect(exitCode).toEqual(0);
});

if (env.CI) {
if (env.CI && !env.BUN) {
test("global", async () => {
await execa("npm", ["i", "-g", "."]);
const {stdout, stderr, exitCode} = await execa("updates", [
Expand Down
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,8 @@
"vite-config-silverwind": "2.1.4",
"vitest": "1.6.0",
"vitest-config-silverwind": "9.0.6"
}
},
"trustedDependencies": [
"restana"
]
}

0 comments on commit 1200c57

Please sign in to comment.