Skip to content

test: double fragment on navigation#93132

Draft
icyJoseph wants to merge 3 commits into
canaryfrom
fix/double-fragment
Draft

test: double fragment on navigation#93132
icyJoseph wants to merge 3 commits into
canaryfrom
fix/double-fragment

Conversation

@icyJoseph
Copy link
Copy Markdown
Member

@icyJoseph icyJoseph commented Apr 22, 2026

Adds a failing e2e for #93126

Repro:

  • from / navigate to /abc#foo
  • on /abc#foo - now click /abc#bar
  • the url is now at /abc#foo#bar

@github-actions
Copy link
Copy Markdown
Contributor

Failing test suites

Commit: 1a18531 | About building and testing Next.js

pnpm test test/integration/create-next-app/package-manager/pnpm.test.ts (job)

  • create-next-app with package manager pnpm > should use pnpm for --use-pnpm flag (DD)
  • create-next-app with package manager pnpm > should use pnpm when user-agent is pnpm (DD)
Expand output

● create-next-app with package manager pnpm › should use pnpm for --use-pnpm flag

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  86 |   for (const file of files) {
  87 |     try {
> 88 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  89 |     } catch (err) {
  90 |       require('console').error(
  91 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:88:54)
  at integration/create-next-app/package-manager/pnpm.test.ts:51:30
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager/pnpm.test.ts:29:5)

● create-next-app with package manager pnpm › should use pnpm when user-agent is pnpm

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  86 |   for (const file of files) {
  87 |     try {
> 88 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  89 |     } catch (err) {
  90 |       require('console').error(
  91 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:88:54)
  at integration/create-next-app/package-manager/pnpm.test.ts:82:30
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager/pnpm.test.ts:60:5)

pnpm test-dev test/e2e/app-dir/navigation/navigation.test.ts (job)

  • app dir - navigation > cross-pathname Link then same-pathname hash change > should replace (not concatenate) the hash when triggers the same-pathname hash change (DD)
Expand output

● app dir - navigation › cross-pathname Link then same-pathname hash change › should replace (not concatenate) the hash when triggers the same-pathname hash change

expect(received).resolves.toEqual(expected) // deep equality

Expected: "http://localhost:41349/hash-cross-path-push/destination#baz"
Received: "http://localhost:41349/hash-cross-path-push/destination#foo#baz"

  375 |       await browser.elementByCss('#link-to-target-baz').click()
  376 |       await retry(() =>
> 377 |         expect(browser.url()).resolves.toEqual(
      |                                        ^
  378 |           next.url + destinationPath + '#baz'
  379 |         )
  380 |       )

  at Object.toEqual (../node_modules/.pnpm/expect@29.7.0/node_modules/expect/build/index.js:174:22)
  at toEqual (e2e/app-dir/navigation/navigation.test.ts:377:40)
  at fn (lib/next-test-utils.ts:862:20)
  at Object.<anonymous> (e2e/app-dir/navigation/navigation.test.ts:376:7)

pnpm test-dev test/e2e/app-dir/pnpm-workspace-root/pnpm-workspace-root.test.ts (job)

  • pnpm-workspace-root > should detect root directory from pnpm-workspace.yaml and allow imports from outside app dir (DD)
  • pnpm-workspace-root > should not have multiple lockfiles warning when pnpm-workspace.yaml is present (DD)
Expand output

● pnpm-workspace-root › should detect root directory from pnpm-workspace.yaml and allow imports from outside app dir

Command failed with exit code 1 (EPERM): pnpm install --strict-peer-dependencies=false --no-frozen-lockfile --config.cacheDir=/tmp --prefer-offline

  23 |   }
  24 |
> 25 |   await execa('pnpm', args, {
     |   ^
  26 |     cwd,
  27 |     stdio: ['ignore', 'inherit', 'inherit'],
  28 |     env: {

  at makeError (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/lib/error.js:58:11)
  at handlePromise (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/index.js:112:26)
  at installDependencies (lib/create-next-install.js:25:3)
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at lib/create-next-install.js:214:9
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNextInstall (lib/create-next-install.js:65:10)
  at lib/next-modes/base.ts:326:13
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at NextDevInstance.createTestDir (lib/next-modes/base.ts:231:5)
  at NextDevInstance.setup (lib/next-modes/next-dev.ts:17:5)
  at lib/e2e-utils/index.ts:276:7
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNext (lib/e2e-utils/index.ts:241:12)
  at Object.<anonymous> (lib/e2e-utils/index.ts:331:14)

● pnpm-workspace-root › should not have multiple lockfiles warning when pnpm-workspace.yaml is present

Command failed with exit code 1 (EPERM): pnpm install --strict-peer-dependencies=false --no-frozen-lockfile --config.cacheDir=/tmp --prefer-offline

  23 |   }
  24 |
> 25 |   await execa('pnpm', args, {
     |   ^
  26 |     cwd,
  27 |     stdio: ['ignore', 'inherit', 'inherit'],
  28 |     env: {

  at makeError (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/lib/error.js:58:11)
  at handlePromise (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/index.js:112:26)
  at installDependencies (lib/create-next-install.js:25:3)
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at lib/create-next-install.js:214:9
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNextInstall (lib/create-next-install.js:65:10)
  at lib/next-modes/base.ts:326:13
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at NextDevInstance.createTestDir (lib/next-modes/base.ts:231:5)
  at NextDevInstance.setup (lib/next-modes/next-dev.ts:17:5)
  at lib/e2e-utils/index.ts:276:7
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNext (lib/e2e-utils/index.ts:241:12)
  at Object.<anonymous> (lib/e2e-utils/index.ts:331:14)

pnpm test-start test/e2e/app-dir/pnpm-workspace-root/pnpm-workspace-root.test.ts (job)

  • pnpm-workspace-root > should detect root directory from pnpm-workspace.yaml and allow imports from outside app dir (DD)
  • pnpm-workspace-root > should not have multiple lockfiles warning when pnpm-workspace.yaml is present (DD)
Expand output

● pnpm-workspace-root › should detect root directory from pnpm-workspace.yaml and allow imports from outside app dir

Command failed with exit code 1 (EPERM): pnpm install --strict-peer-dependencies=false --no-frozen-lockfile --config.cacheDir=/tmp --prefer-offline

  23 |   }
  24 |
> 25 |   await execa('pnpm', args, {
     |   ^
  26 |     cwd,
  27 |     stdio: ['ignore', 'inherit', 'inherit'],
  28 |     env: {

  at makeError (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/lib/error.js:58:11)
  at handlePromise (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/index.js:112:26)
  at installDependencies (lib/create-next-install.js:25:3)
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at lib/create-next-install.js:214:9
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNextInstall (lib/create-next-install.js:65:10)
  at lib/next-modes/base.ts:326:13
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at NextStartInstance.createTestDir (lib/next-modes/base.ts:231:5)
  at NextStartInstance.setup (lib/next-modes/next-start.ts:45:5)
  at lib/e2e-utils/index.ts:276:7
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNext (lib/e2e-utils/index.ts:241:12)
  at Object.<anonymous> (lib/e2e-utils/index.ts:331:14)

● pnpm-workspace-root › should not have multiple lockfiles warning when pnpm-workspace.yaml is present

Command failed with exit code 1 (EPERM): pnpm install --strict-peer-dependencies=false --no-frozen-lockfile --config.cacheDir=/tmp --prefer-offline

  23 |   }
  24 |
> 25 |   await execa('pnpm', args, {
     |   ^
  26 |     cwd,
  27 |     stdio: ['ignore', 'inherit', 'inherit'],
  28 |     env: {

  at makeError (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/lib/error.js:58:11)
  at handlePromise (../node_modules/.pnpm/execa@2.0.3/node_modules/execa/index.js:112:26)
  at installDependencies (lib/create-next-install.js:25:3)
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at lib/create-next-install.js:214:9
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNextInstall (lib/create-next-install.js:65:10)
  at lib/next-modes/base.ts:326:13
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at NextStartInstance.createTestDir (lib/next-modes/base.ts:231:5)
  at NextStartInstance.setup (lib/next-modes/next-start.ts:45:5)
  at lib/e2e-utils/index.ts:276:7
  at Span.traceAsyncFn (../packages/next/src/trace/trace.ts:146:14)
  at createNext (lib/e2e-utils/index.ts:241:12)
  at Object.<anonymous> (lib/e2e-utils/index.ts:331:14)

Other failing CI jobs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant