Closed keyansheng closed 4 months ago
Right now the first 2 tests depend on the current state of the production database, and would fail if the data in the production database is changed
yeah this is definitely not good testing practice.
probably can just remove those for now
maybe we could use beforeEach
to set up the database before each test
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
timetable-together | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Jun 28, 2024 3:21pm |
should be beforeAll
since we are just setting up the database once for all the database tests
alternatively we can just set up a dev database, then we wouldn’t have to worry about this
hmmm we don't actually have a function for inserting events
I suppose we can just use the prisma functions directly in tests for now
looks good enough, going to merge once and then we can merge again when we have more tests
Resolves #19