-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: flashdagger <flashdagger@googlemail.com>
- Loading branch information
1 parent
9da13ab
commit 7a87cec
Showing
4 changed files
with
23 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/bin/env python | ||
# -*- coding: UTF-8 -*- | ||
|
||
|
||
def test_create_group(rclient, temporary_resources): | ||
with temporary_resources("groups") as groups: | ||
new_group = rclient.groups.create("pytest_group") | ||
groups.append(new_group.view()) | ||
assert new_group.active is True | ||
assert new_group.note is None | ||
|
||
|
||
def test_group_users_attribute(client): | ||
group = client.groups(1, info={"id": 1, "user_ids": [1, 2, 3]}) | ||
users = client.users | ||
assert group.users == [users(1), users(2), users(3)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{"method": "POST", "url": "https://localhost/api/v1/groups", "status_code": 201, "reason": "Created", "headers": {"Content-Type": "application/json; charset=utf-8", "Content-Length": "359"}, "encoding": "utf-8", "content_size": 359} | ||
{"id":5,"signature_id":null,"email_address_id":null,"name":"pytest_group","assignment_timeout":null,"follow_up_possible":"yes","reopen_time_in_days":null,"follow_up_assignment":true,"active":true,"shared_drafts":true,"note":null,"updated_by_id":3,"created_by_id":3,"created_at":"2023-10-27T04:24:41.236Z","updated_at":"2023-10-27T04:24:41.236Z","user_ids":[]} | ||
{"method": "DELETE", "url": "https://localhost/api/v1/groups/5#fixture", "status_code": 200, "reason": "OK", "headers": {"Content-Type": "application/json; charset=utf-8", "Content-Length": "2"}, "encoding": "utf-8", "content_size": 2} | ||
{} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters