Skip to content

Commit fbed056

Browse files
authored
chore: pin pnpm for corepack (#1831)
1 parent 2e77770 commit fbed056

File tree

15 files changed

+455
-385
lines changed

15 files changed

+455
-385
lines changed

.github/workflows/cr.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,12 @@ jobs:
2020
- uses: actions/checkout@v4
2121

2222
- uses: pnpm/action-setup@v3
23-
with:
24-
# https://github.com/pnpm/pnpm/issues/8953
25-
version: 9.15.3
2623

27-
- name: Use Node.js 20
24+
- name: Use Node.js from .nvmrc
2825
uses: actions/setup-node@v4
2926
with:
30-
node-version: 20
27+
node-version-file: ".nvmrc"
28+
registry-url: "https://registry.npmjs.org"
3129
cache: "pnpm"
3230

3331
- name: Install dependencies

.github/workflows/release.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,13 @@ jobs:
1616
uses: actions/checkout@v3
1717

1818
- uses: pnpm/action-setup@v3
19-
with:
20-
# https://github.com/pnpm/pnpm/issues/8953
21-
version: 9.15.3
2219

2320
- name: Use Node.js from nvmrc
2421
uses: actions/setup-node@v4
2522
with:
2623
node-version-file: ".nvmrc"
2724
registry-url: "https://registry.npmjs.org"
25+
cache: "pnpm"
2826

2927
- name: Install Dependencies
3028
run: pnpm i --frozen-lockfile

.github/workflows/tests.yml

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,17 @@ on:
1010
jobs:
1111
tests:
1212
name: "🧪 Tests"
13-
runs-on: ubuntu-22.04
13+
runs-on: ubuntu-24.04
1414
steps:
1515
- uses: actions/checkout@v3
1616
- uses: pnpm/action-setup@v4
17+
18+
- name: Use Node.js from nvmrc
19+
uses: actions/setup-node@v4
1720
with:
18-
# https://github.com/pnpm/pnpm/issues/8953
19-
version: 9.15.3
21+
node-version-file: ".nvmrc"
22+
registry-url: "https://registry.npmjs.org"
23+
cache: "pnpm"
2024

2125
- name: Install project dependencies
2226
run: pnpm i
@@ -36,18 +40,22 @@ jobs:
3640
working-directory: .
3741
runTests: false
3842

39-
- name: E2E Firefox
43+
- name: E2E Chromium
4044
uses: cypress-io/github-action@v6
4145
with:
4246
install: false
4347
working-directory: packages/tests
44-
start: pnpm start
45-
browser: firefox
48+
start: pnpm start --host 127.0.0.1 --port 3000
49+
wait-on: 'http://127.0.0.1:3000'
50+
browser: chromium
4651

47-
- name: E2E Chromium
52+
- name: E2E Firefox
4853
uses: cypress-io/github-action@v6
4954
with:
5055
install: false
5156
working-directory: packages/tests
52-
start: pnpm start
53-
browser: chromium
57+
start: pnpm start --host 127.0.0.1 --port 3000
58+
wait-on: 'http://127.0.0.1:3000'
59+
browser: firefox
60+
61+

.github/workflows/typecheck.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,12 @@ jobs:
4646
- uses: actions/checkout@v4
4747

4848
- uses: pnpm/action-setup@v3
49-
with:
50-
# https://github.com/pnpm/pnpm/issues/8953
51-
version: 9.15.3
5249

53-
- name: Use Node.js ${{ matrix.node-version }}
50+
- name: Use Node.js from .nvmrc
5451
uses: actions/setup-node@v4
5552
with:
56-
node-version: ${{ matrix.node-version }}
53+
node-version-file: ".nvmrc"
54+
registry-url: "https://registry.npmjs.org"
5755
cache: "pnpm"
5856

5957
- name: Install dependencies

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@
4040
},
4141
"dependencies": {},
4242
"engines": {
43-
"pnpm": "^9.0.0"
44-
}
43+
"pnpm": "^9.15.0",
44+
"node": ">=22"
45+
},
46+
"packageManager": "pnpm@9.15.0"
4547
}

packages/tests/app.config.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
11
import { defineConfig } from "@solidjs/start/config";
22

3-
export default defineConfig({
4-
ssr: false
5-
});
3+
export default defineConfig();
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
describe("hydration", () => {
2+
it("should have interactivity", () => {
3+
cy.visit("/");
4+
cy.get("#counter-button").trigger("click")
5+
cy.get("#counter-output").contains("1");
6+
});
7+
8+
it("should have isServer false in the client", () => {
9+
cy.visit("/client-only");
10+
cy.get("#server-fn-test").contains('{"clientWithIsServer":false}');
11+
});
12+
});

packages/tests/cypress/e2e/server-function.cy.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
describe("server-function", () => {
2-
it("should have isServer false in the client", () => {
3-
cy.visit("/");
4-
cy.get("#server-fn-test").contains('{"clientWithIsServer":false}');
5-
});
62
it("should have isServer true in the server function - nested", () => {
73
cy.visit("/is-server-nested");
84
cy.get("#server-fn-test").contains('{"serverFnWithIsServer":true}');

packages/tests/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
"@vitest/ui": "3.0.5",
2424
"jsdom": "^25.0.1",
2525
"lodash": "^4.17.21",
26-
"solid-js": "^1.9.4",
26+
"solid-js": "^1.9.5",
2727
"vinxi": "^0.5.3",
28-
"vite-plugin-solid": "^2.11.1",
28+
"vite-plugin-solid": "^2.11.6",
2929
"vitest": "3.0.5"
3030
},
3131
"engines": {

packages/tests/src/app.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ export default function App() {
1212
<Title>SolidStart - Basic</Title>
1313
<ul>
1414
<li>
15-
<a href="/">Client</a>
15+
<a href="/">Basic</a>
16+
</li>
17+
<li>
18+
<a href="/client-only">Client-Only</a>
1619
</li>
1720
<li>
1821
<a href="/is-server-nested">isserver (nested)</a>

packages/tests/src/routes/(basic).tsx

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import { createSignal } from "solid-js";
2+
3+
export default function App() {
4+
const [counter, setCounter] = createSignal<number>(0);
5+
6+
return (
7+
<main>
8+
<span id="counter-output">{counter()}</span>
9+
<button id="counter-button" onClick={() => setCounter(n => n + 1)}>one more</button>
10+
</main>
11+
);
12+
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import { createSignal } from "solid-js";
2+
import { isServer } from "solid-js/web";
3+
4+
5+
export default function ClientOnlyComponent() {
6+
const [output, setOutput] = createSignal<{ clientWithIsServer?: boolean; }>({});
7+
8+
setOutput(prev => ({ ...prev, clientWithIsServer: isServer }));
9+
10+
return (
11+
<main>
12+
<span id="server-fn-test">{JSON.stringify(output())}</span>
13+
</main>)
14+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import { clientOnly } from "@solidjs/start";
2+
3+
const Component = clientOnly(() => import('./_component'))
4+
5+
export default function App() {
6+
7+
return (
8+
<>
9+
<Component />
10+
</>
11+
);
12+
}

packages/tests/src/routes/index.tsx

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)