Fixed navigation race in Admin sidebar acceptance test - #29323
Conversation
no ref The Network route redirects through ActivityPub onboarding, so waiting for transient paths allowed the redirect to race the subsequent Posts navigation.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
WalkthroughThe sidebar acceptance test now asserts that selecting Network navigates to Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
| Command | Status | Duration | Result |
|---|---|---|---|
nx run-many --target=build --projects=tag:publi... |
✅ Succeeded | 3s | View ↗ |
nx run @tryghost/admin:build |
✅ Succeeded | 2m 31s | View ↗ |
nx run-many -t test:unit -p @tryghost/admin |
✅ Succeeded | 1m 55s | View ↗ |
nx run ghost-monorepo:lint:boundaries |
✅ Succeeded | <1s | View ↗ |
nx run-many -t lint -p @tryghost/admin |
✅ Succeeded | 48s | View ↗ |
nx run @tryghost/admin:test:acceptance |
✅ Succeeded | 56s | View ↗ |
nx run ghost:build:assets |
✅ Succeeded | 1s | View ↗ |
nx run ghost:build:tsc |
✅ Succeeded | 8s | View ↗ |
💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗
☁️ Nx Cloud last updated this comment at 2026-07-14 17:51:33 UTC

What changed
Why
The test accepted the transient
/networkroute even though its loader redirects into ActivityPub. It could then click Posts while the ActivityPub redirect was still pending. When that redirect won the race, the test remained on ActivityPub and the badge was correctly hidden, causing the recurring CI failure.Impact
This makes the sidebar acceptance test deterministic without changing production behavior or Vite dependency optimization.
Validation
pnpm nx run @tryghost/admin:test:acceptance -- src/layout/sidebar.acceptance.test.tsx— 16 tests passedpnpm --dir apps/admin exec eslint src/layout/sidebar.acceptance.test.tsx