Files
calendar/apps/web/test
Anik Dhabal BabuGitHubDevin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
fca818a275 test: fix unit test flake (#25557)
* fix: revalidate teams cache after accepting invite via token

When a user accepts a team invite via token on the /teams page, the
teams cache was not being invalidated. This caused the page to show
stale data (empty list) while the sidebar correctly showed the teams.

This fix adds a call to revalidateTeamsList() after processing an
invite token, ensuring the cache is invalidated and fresh data is
fetched immediately.

Co-Authored-By: anik@cal.com <adhabal2002@gmail.com>

* fix: revalidate teams cache after creating team in onboarding flow

Co-Authored-By: anik@cal.com <adhabal2002@gmail.com>

* Remove comments on teams cache revalidation

Removed comments about revalidating teams cache after invite processing.

* fix unit test flake

* Remove unused import in useCreateTeam hook

Removed unused import for revalidateTeamsList.

* Remove unused import for revalidateTeamsList

---------

Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-01-06 11:14:28 +05:30
..
2026-01-02 12:47:00 +00:00
2026-01-02 12:47:00 +00:00
2022-07-22 18:39:50 -06:00

Unit and Integration Tests

Make sure you have copied .env.test.example to .env.test

You can run all jest tests as

yarn test

You can run tests matching specific description by following command yarn test -t getSchedule

Tip: Use --watchAll flag to run tests on every change