habitica/test/api/unit/models
Phillip Thelen 8150fef993
Database Access optimisations (#14544)
* Optimize database access during spell casting

* load less data when casting spells

* Begin migrating update calls to updateOne and updateMany

* Only update user objects that don’t have notification yet

* fix test

* fix spy

* Don’t unnecessarily update user when requesting invalid guild

* fix sort order for middlewares to not load user twice every request

* fix tests

* fix integration test

* fix skill usage not always deducting mp

* addtest case for blessing spell

* fix healAll

* fix lint

* Fix error for when some spells are used outside of party

* Add check to not run bulk spells in web client

* fix(tags): change const to let

---------

Co-authored-by: SabreCat <sabe@habitica.com>
2023-05-16 12:21:45 -05:00
..
challenge.test.js Added code to update user tag list along with the existing code that already involves updating the user documents of challenge members (#12312) 2020-07-03 21:55:59 +02:00
group.test.js Database Access optimisations (#14544) 2023-05-16 12:21:45 -05:00
group_tasks.test.js fix(teams): tweak FAQ and fix sync test 2022-08-22 14:43:21 -05:00
message.test.js tests(message model): add unit tests 2020-03-04 17:51:14 +01:00
newsPost.js Implement Bailey CMS API (#10739) 2020-10-13 10:15:52 -05:00
pushDevice.test.js add final tests for push devices and notifications 2020-03-01 22:10:11 +01:00
tag.test.js fix tags 2020-03-01 22:21:53 +01:00
task.test.js fix(teams): fix fix fix 2022-08-22 16:16:23 -05:00
user.test.js refactor(achievements): crush down to much fewer notification types 2022-05-12 15:25:40 -05:00
userNotification.test.js add final tests for push devices and notifications 2020-03-01 22:10:11 +01:00
webhook.test.js chore: update sub-deps and fix lint 2020-07-01 18:20:18 +02:00