Skip to content

Commit f7f58c9

Browse files
committed
Merge remote-tracking branch 'upstream/main'
2 parents cc3413b + 1a6bda2 commit f7f58c9

File tree

24 files changed

+211
-175
lines changed

24 files changed

+211
-175
lines changed
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
name: "Setup Playwright"
2+
description: "Setup Playwright with pnpm (should already be installed)"
3+
runs:
4+
using: "composite"
5+
steps:
6+
- name: Install Playwright
7+
shell: bash
8+
run: pnpm exec playwright install --with-deps chromium

.github/actions/setup/action.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: 'Setup Environment'
2+
description: 'Sets up Node.js and pnpm'
3+
runs:
4+
using: composite
5+
steps:
6+
- name: Install pnpm
7+
uses: pnpm/action-setup@v4
8+
with:
9+
version: 9.3.0
10+
11+
- name: Install Node.js
12+
uses: actions/setup-node@v4
13+
with:
14+
node-version: 20
15+
cache: 'pnpm'
16+
17+
- name: Install dependencies
18+
shell: bash
19+
run: pnpm install --frozen-lockfile
20+
21+
- name: Install Playwright Browsers and Dependencies
22+
shell: bash
23+
run: pnpm exec playwright install --with-deps

.github/workflows/pages-deployment.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ jobs:
1818
- name: Checkout
1919
uses: actions/checkout@v4
2020

21+
- name: Update apt-get
22+
run: sudo apt-get update
23+
2124
- name: Install Misc. Deps
2225
run: sudo apt-get install -y libcairo2-dev libjpeg8-dev libpango1.0-dev libgif-dev build-essential g++
2326

.github/workflows/test.yaml

Lines changed: 15 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -7,53 +7,27 @@ env:
77

88
jobs:
99
coverage:
10-
runs-on: ubuntu-latest
10+
runs-on: blacksmith-4vcpu-ubuntu-2404
1111
steps:
1212
- uses: actions/checkout@v4
13-
14-
- name: Install corepack
15-
run: npm i -g corepack
16-
17-
- name: Install pnpm
18-
run: npm i -g --force corepack && corepack enable pnpm
19-
20-
- name: Install Node.js
21-
uses: actions/setup-node@v4
22-
with:
23-
node-version: 20
24-
cache: 'pnpm'
25-
26-
- run: pnpm install --frozen-lockfile
13+
- uses: ./.github/actions/setup
2714

2815
- name: Get contract addresses
2916
run: 'parallel --lb --halt now,success=1,fail=1 ::: \
30-
"pnpm tenv start --no-graph --no-scripts --no-build --exit-after-deploy" \
17+
"pnpm tenv start --no-ensnode --no-scripts --no-build --exit-after-deploy --verbosity 1" \
3118
"pnpm wait-on ./.env.local"'
3219

3320
- run: pnpm test:coverage
3421

3522
build-stateless:
36-
runs-on: ubuntu-latest
23+
runs-on: blacksmith-4vcpu-ubuntu-2404
3724
steps:
3825
- uses: actions/checkout@v4
39-
40-
- name: Install corepack
41-
run: npm i -g corepack
42-
43-
- name: Install pnpm
44-
run: npm i -g --force corepack && corepack enable pnpm
45-
46-
- name: Install Node.js
47-
uses: actions/setup-node@v4
48-
with:
49-
node-version: 20
50-
cache: 'pnpm'
51-
52-
- run: pnpm install --frozen-lockfile
26+
- uses: ./.github/actions/setup
5327

5428
- name: Get contract addresses
5529
run: 'parallel --lb --halt now,success=1,fail=1 ::: \
56-
"pnpm tenv start --no-graph --no-scripts --no-build --exit-after-deploy" \
30+
"pnpm tenv start --no-ensnode --no-scripts --no-build --exit-after-deploy --verbosity 1" \
5731
"pnpm wait-on ./.env.local"'
5832

5933
- name: Build stateless and export
@@ -69,23 +43,10 @@ jobs:
6943
path: stateless-build.tar
7044

7145
build-stateful:
72-
runs-on: ubuntu-latest
46+
runs-on: blacksmith-4vcpu-ubuntu-2404
7347
steps:
7448
- uses: actions/checkout@v4
75-
76-
- name: Install corepack
77-
run: npm i -g corepack
78-
79-
- name: Install pnpm
80-
run: npm i -g --force corepack && corepack enable pnpm
81-
82-
- name: Install Node.js
83-
uses: actions/setup-node@v4
84-
with:
85-
node-version: 20
86-
cache: 'pnpm'
87-
88-
- run: pnpm install --frozen-lockfile
49+
- uses: ./.github/actions/setup
8950

9051
- name: Build stateful and export
9152
run: pnpm build && pnpm export
@@ -103,7 +64,7 @@ jobs:
10364
name: stateless (${{matrix.shard}})
10465
needs: build-stateless
10566
timeout-minutes: 20
106-
runs-on: ubuntu-latest
67+
runs-on: blacksmith-4vcpu-ubuntu-2404
10768
strategy:
10869
matrix:
10970
shard:
@@ -140,20 +101,8 @@ jobs:
140101
]
141102
steps:
142103
- uses: actions/checkout@v4
143-
144-
- name: Install corepack
145-
run: npm i -g corepack
146-
147-
- name: Install pnpm
148-
run: npm i -g --force corepack && corepack enable pnpm
149-
150-
- name: Install Node.js
151-
uses: actions/setup-node@v4
152-
with:
153-
node-version: 20
154-
cache: 'pnpm'
155-
156-
- run: pnpm install --frozen-lockfile
104+
- uses: ./.github/actions/setup
105+
- uses: ./.github/actions/setup-playwright
157106

158107
- run: pnpm rebuild -r
159108

@@ -167,9 +116,6 @@ jobs:
167116
- name: Untar files
168117
run: tar -xvf stateless-build.tar
169118

170-
- name: Install playwright
171-
run: pnpm playwright install chromium
172-
173119
- name: Run tests
174120
run: |
175121
PLAYWRIGHT_SHARD=${{matrix.shard}} PLAYWRIGHT_TOTAL=${{strategy.job-total}} pnpm e2e:ci --no-build
@@ -186,28 +132,14 @@ jobs:
186132
name: stateful (${{matrix.shard}})
187133
needs: build-stateful
188134
timeout-minutes: 10
189-
runs-on: ubuntu-latest
135+
runs-on: blacksmith-4vcpu-ubuntu-2404
190136
strategy:
191137
matrix:
192138
shard: [1, 2, 3]
193-
194139
steps:
195140
- uses: actions/checkout@v4
196-
- run: ./scripts/check-chrome.sh
197-
198-
- name: Install corepack
199-
run: npm i -g corepack
200-
201-
- name: Install pnpm
202-
run: npm i -g --force corepack && corepack enable pnpm
203-
204-
- name: Install Node.js
205-
uses: actions/setup-node@v4
206-
with:
207-
node-version: 20
208-
cache: 'pnpm'
209-
210-
- run: pnpm install --frozen-lockfile
141+
- uses: ./.github/actions/setup
142+
- uses: ./.github/actions/setup-playwright
211143

212144
- run: pnpm rebuild -r
213145

@@ -220,16 +152,12 @@ jobs:
220152
- name: Untar files
221153
run: tar -xvf stateful-build.tar
222154

223-
- name: Install playwright
224-
run: pnpm playwright install chromium
225-
226155
- name: Run tests
227156
run: |
228157
parallel --lb --halt now,success=1,fail=1 ::: \
229158
"pnpm wrangle" \
230-
"pnpm wait-on http://127.0.0.1:8788 && pnpm playwright test --shard=${{matrix.shard}}/${{strategy.job-total}} --project=stateful"
159+
"pnpm wait-on http://127.0.0.1:8788 && npx playwright test --shard=${{matrix.shard}}/${{strategy.job-total}} --project=stateful"
231160
env:
232-
NEXT_PUBLIC_CHAIN_NAME: holesky
233161
SECRET_WORDS: ${{ secrets.SECRET_WORDS }}
234162

235163
- uses: actions/upload-artifact@v4

archive.tar.gz

-7.75 MB
Binary file not shown.

e2e/specs/stateful/dnsclaim.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ test.describe('Import DNSSEC name', () => {
2121
page,
2222
login,
2323
}) => {
24-
await page.goto('/noenssubdomain.com?chain=holesky')
24+
await page.goto('/setupu.xyz?chain=holesky')
2525
await login.connect()
2626

2727
await page.getByTestId('onchain-radio').click()
@@ -35,7 +35,7 @@ test.describe('Import DNSSEC name', () => {
3535
page,
3636
login,
3737
}) => {
38-
await page.goto('/noenssubdomain.com?chain=holesky')
38+
await page.goto('/setupu.xyz?chain=holesky')
3939
await login.connect()
4040

4141
await page.getByTestId('offchain-radio').click()
@@ -45,7 +45,7 @@ test.describe('Import DNSSEC name', () => {
4545
await expect(page.getByTestId('offchain-claim')).toBeDisabled()
4646
})
4747

48-
test('should not allow the user to proceed if they have not set the correct subdomain with the correct info', async ({
48+
test.skip('should not allow the user to proceed if they have not set the correct subdomain with the correct info', async ({
4949
page,
5050
login,
5151
}) => {

e2e/specs/stateless/extendNames.spec.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -740,6 +740,9 @@ test('should handle URL-based renew for disconnected users', async ({ page, make
740740
owner: 'user',
741741
})
742742

743+
await page.goto(`/${name}?tab=ownership`)
744+
await expect(page.getByText('Extend')).not.toBeVisible()
745+
743746
await page.goto(`/${name}?renew=94608000`)
744747
await expect(page.getByText('Connect a wallet')).toBeVisible()
745748
})

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,22 @@
88
"dev:https": "next dev --experimental-https --port 443",
99
"dev:https:holesky": "NEXT_PUBLIC_CHAIN_NAME=holesky pnpm dev:https",
1010
"dev:https:sepolia": "NEXT_PUBLIC_CHAIN_NAME=sepolia pnpm dev:https",
11+
"dev:https:mainnet": "NEXT_PUBLIC_CHAIN_NAME=mainnet pnpm dev:https",
1112
"dev:nlocal": "NEXT_PUBLIC_PROVIDER=http://localhost:8545 NEXT_PUBLIC_AVUP_ENDPOINT=http://localhost:8787 pnpm dev",
1213
"dev:localname": "NEXT_PUBLIC_PROVIDER=\"http://$(\"hostname\"):8545\" && NEXT_PUBLIC_AVUP_ENDPOINT=\"http://$(\"hostname\"):8787\" && NEXT_PUBLIC_GRAPH_URI=\"http://$(\"hostname\"):8000/subgraphs/name/graphprotocol/ens\" && pnpm dev",
13-
"dev:glocal": "SWC_CACHE=false rm -rf .next && NEXT_PUBLIC_GRAPH_URI=http://localhost:8000/subgraphs/name/graphprotocol/ens NEXT_PUBLIC_ETH_NODE=anvil pnpm dev:nlocal",
14+
"dev:glocal": "SWC_CACHE=false rm -rf .next && NEXT_PUBLIC_GRAPH_URI=http://localhost:42069/subgraph NEXT_PUBLIC_ETH_NODE=anvil pnpm dev:nlocal",
1415
"dev:gonline": "NEXT_PUBLIC_GRAPH_URI=https://api.studio.thegraph.com/query/49574/ensholesky/version/latest pnpm dev",
1516
"build": "next build",
1617
"build:preview": "NEXT_PUBLIC_ENSJS_DEBUG=true next build --profile",
1718
"build:local": "ANALYZE=true next build",
18-
"build:glocal": "NEXT_PUBLIC_GRAPH_URI=http://localhost:8000/subgraphs/name/graphprotocol/ens NEXT_PUBLIC_PROVIDER=http://localhost:8545 NEXT_PUBLIC_ETH_NODE=anvil pnpm build",
19+
"build:glocal": "NEXT_PUBLIC_GRAPH_URI=http://localhost:42069/subgraph NEXT_PUBLIC_PROVIDER=http://localhost:8545 NEXT_PUBLIC_ETH_NODE=anvil pnpm build",
1920
"build:localname": "NEXT_PUBLIC_PROVIDER=\"http://$(\"hostname\"):8545\" && NEXT_PUBLIC_GRAPH_URI=\"http://$(\"hostname\"):8000/subgraphs/name/graphprotocol/ens\" && pnpm build",
2021
"start": "next start",
2122
"buildandstart": "pnpm build && pnpm start",
2223
"buildandexport": "pnpm build && pnpm export",
2324
"buildandstart:glocal": "pnpm build:glocal && pnpm start",
2425
"tenv": "ens-test-env -a",
25-
"denv": "pnpm tenv start --no-scripts --no-build --extra-time 12232000 --verbosity 1",
26+
"denv": "pnpm tenv start --no-scripts --no-build --extra-time 11368000 --verbosity 1",
2627
"lint": "next lint && stylelint \"./src/**/*.tsx\"",
2728
"lint:types": "tsc --noEmit",
2829
"lint:fix": "next lint --fix",
@@ -36,7 +37,7 @@
3637
"e2e:install": "npx playwright install chromium",
3738
"e2e": "npx playwright test --project=stateless",
3839
"e2e:stateful": "playwright test --project=stateful",
39-
"e2e:ci": "E2E=true CI=true STABLE_MODE=true SLOW_MODE=true pnpm tenv start --extra-time 11368000",
40+
"e2e:ci": "E2E=true CI=true STABLE_MODE=true SLOW_MODE=true pnpm tenv start --extra-time 11368000 --verbosity 1",
4041
"postinstall": "husky install",
4142
"wrangle": "wrangler pages dev ./out --local --log-level none",
4243
"wrangle:dev": "wrangler pages dev ./next",
@@ -54,9 +55,9 @@
5455
"@ensdomains/address-encoder": "1.1.1",
5556
"@ensdomains/content-hash": "^3.0.0-beta.5",
5657
"@ensdomains/ens-contracts": "1.4.0-beta.2",
57-
"@ensdomains/ens-test-env": "0.6.0",
58+
"@ensdomains/ens-test-env": "1.0.1",
5859
"@ensdomains/ensjs": "4.0.3-alpha.12",
59-
"@ensdomains/thorin": "1.0.0-beta.26",
60+
"@ensdomains/thorin": "1.0.0-beta.28",
6061
"@getpara/rainbowkit": "1.3.0",
6162
"@getpara/rainbowkit-wallet": "1.3.0",
6263
"@metamask/post-message-stream": "^6.1.2",
@@ -287,8 +288,7 @@
287288
"node-forge@1.3.1": "patches/node-forge@1.3.1.patch",
288289
"react-confetti@6.1.0": "patches/react-confetti@6.1.0.patch",
289290
"hardhat-deploy@0.12.4": "patches/hardhat-deploy@0.12.4.patch",
290-
"@nomicfoundation/hardhat-viem@2.0.3": "patches/@nomicfoundation%2Fhardhat-viem@2.0.3.patch",
291-
"@ensdomains/ens-test-env@0.6.0": "patches/@ensdomains__ens-test-env@0.6.0.patch"
291+
"@nomicfoundation/hardhat-viem@2.0.3": "patches/@nomicfoundation%2Fhardhat-viem@2.0.3.patch"
292292
}
293293
},
294294
"packageManager": "pnpm@9.3.0"

patches/@ensdomains__ens-test-env@0.6.0.patch

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

playwright/fixtures/subgraph.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ export const waitForSubgraph = () => async () => {
2626
const anvilBlockNumbers: number[] = []
2727
do {
2828
await new Promise((resolve) => setTimeout(resolve, 500))
29-
const client = new GraphQLClient('http://localhost:8000/subgraphs/name/graphprotocol/ens')
29+
const client = new GraphQLClient('http://localhost:42069/subgraph')
3030
const res = await client.request<{_meta: {block: {number: number}}}>(query)
3131

3232
anvilBlockNumbers.push(res._meta.block.number)

0 commit comments

Comments
 (0)