Skip to content

flake: template update with new name redirects on successful submit #1403

@flake-investigator

Description

@flake-investigator

CI Run: https://github.com/coder/coder/actions/runs/23095543425 (job: test-e2e)
Commit: 1adc22fffdd5e710f302466eb952af40961b5d77 (Mathias Fredriksson)

Failing test:

  • e2e/tests/updateTemplate.spec.ts:20:5 › template update with new name redirects on successful submit

Error excerpt:

Error: The page does not have the expected URL pathname.
Expected a url ending with: "/new-name"
Actual: "/templates/new-name/docs"
  at helpers.ts:1160

What happened:

  • updateTemplateSettings navigates to linkToTemplate(...) after save.
  • /templates/:template now redirects to /templates/:template/docs (router index route).
  • The helper still expects the URL to end with /${name}, so the redirect causes a deterministic failure.

Suggested fix:

  • Update updateTemplateSettings to accept the docs landing page (e.g., toHavePathNameEndingWith(/${name}/docs)), or adjust the navigation expectation to use linkToTemplate(...) + "/docs".

Assignment analysis (best effort):

  • git log --oneline -10 --follow site/e2e/tests/updateTemplate.spec.ts -> 15a2bab1 (Jake Howell, 2026-02-25)
  • git log --oneline -10 --follow site/src/pages/TemplateSettingsPage/TemplateGeneralSettingsPage/TemplateSettingsPage.tsx -> 15a2bab1 (Jake Howell, 2026-02-25)
  • I can’t run git blame in this environment; using the most recent substantive touches to the test and template settings page as the best owner signal.

Suggested assignee: Jake Howell

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions