Skip to content

test: remove obsolete RTK Query API tests#142

Closed
jakebromberg wants to merge 2 commits intomainfrom
fix/remove-obsolete-api-tests
Closed

test: remove obsolete RTK Query API tests#142
jakebromberg wants to merge 2 commits intomainfrom
fix/remove-obsolete-api-tests

Conversation

@jakebromberg
Copy link
Copy Markdown
Member

@jakebromberg jakebromberg commented Feb 3, 2026

Closes #243

Summary

Delete tests for adminApi, authenticationApi, and djRegistryApi
which no longer exist. Authentication is now handled by Better Auth
instead of RTK Query.

Files removed

  • lib/__tests__/features/admin/api.test.ts
  • lib/__tests__/features/authentication/api.test.ts

Test plan

  • These APIs no longer exist in the codebase
  • Tests were causing import failures

Made with Cursor

Note: E2E tests depend on #271 and WXYC/Backend-Service#223. E2E will pass once those merge.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Feb 3, 2026

Deploying wxyc-dj with  Cloudflare Pages  Cloudflare Pages

Latest commit: f285947
Status: ✅  Deploy successful!
Preview URL: https://d43ad09f.dj-site.pages.dev
Branch Preview URL: https://fix-remove-obsolete-api-test-8grx.dj-site.pages.dev

View logs

jakebromberg and others added 2 commits March 8, 2026 18:43
Delete tests for adminApi, authenticationApi, and djRegistryApi
which no longer exist. Authentication is now handled by Better Auth
instead of RTK Query.

Co-authored-by: Cursor <cursoragent@cursor.com>
…rization.ADMIN

The Authorization enum only defines NO, DJ, MD, SM -- there is no ADMIN
member. The RequireAdmin convenience component was referencing
Authorization.ADMIN, causing a TypeScript build failure on Cloudflare
Pages. Removed RequireAdmin and its test since admin/owner roles map to
SM in mapRoleToAuthorization.
@jakebromberg jakebromberg force-pushed the fix/remove-obsolete-api-tests branch from 0ef255f to f285947 Compare March 9, 2026 01:44
@jakebromberg
Copy link
Copy Markdown
Member Author

Closing — the AuthorizedView changes are already on main. The only remaining diff is accidentally committed artifacts (.env.local.bak, conversation.txt, playwright-report/, test-results/, e2e/.auth/).

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Obsolete RTK Query API tests for removed auth modules

2 participants