1
0
Fork 0
mirror of synced 2024-07-06 15:11:21 +12:00
appwrite/app
Safwan Parkar 451f4bee19 Fixed an incorrect test for team deletion
This commit contains changes in 3 places.

- First I changed the placement of an informative comment in the DELETE TEAM controller, and moved it outside of the loop. I did this when Steven pointed out that the behaviour I describe in the comment is for the whole loop.

- The second change is the removal of my first test. I was facing quite a few issues with creating users in the test, and ended up using the CREATE TEAM MEMBERSHIP to perform 2 actions at once -> create a new user if one doesn't exist with the provided email, and create a membership for the user. Before this approach, I had quite a bit of code that didn't work, and it seems like I removed some things that weren't supposed to be removed, and didn't change variable names where necessary. Anyway, I figured that the problem has something to do with the user being created on the client side, so I moved the test to the server side.

- The new test I implemented does the same thing as my previous failed test, but in more detailed and distinct steps. The test first creates 5 new users inside of a loop, and pushes each new user's ID to an array called 'new_users' if the response is as expected. Then a new team is created. The next step is to create memberships for all 5 users. If all these steps pass, the new team that was just created, is deleted, and we check to make sure the new users have 0 team memberships each.

Formatter and linter showed no errors. Tests were successful on localhost.
2023-08-04 15:40:42 +04:00
..
assets Merge branch '1.3.x' into feat-13x-master-sync 2023-02-21 07:38:46 +05:45
config Update Project providers to also include the provider key 2023-07-20 16:53:33 -07:00
console@9174d8f8cb feat: update console 2023-07-11 18:43:28 +00:00
controllers Fixed an incorrect test for team deletion 2023-08-04 15:40:42 +04:00
tasks Update install.php not specify docker-compose.yml file 2023-04-30 12:34:55 -07:00
views add restart policy for worker-messaging container 2023-01-12 06:51:50 +00:00
workers Update Appwrite to save internal id as audit user id 2023-07-19 22:49:51 -07:00
cli.php
executor.php fix: implement new framework changes 2023-03-01 17:30:36 +05:30
http.php remove: leftover from http.php 2023-04-24 13:11:39 +02:00
init.php Prepare 1.3.8 release 2023-07-19 22:49:51 -07:00
preload.php feat: update database library 2022-10-31 12:02:51 +00:00
realtime.php Merge remote-tracking branch 'origin/master' into feat-technical-debt-2 2023-02-14 14:22:08 +13:00