| 1 | from .conftest import get_client, verify_request_count |
| 2 | |
| 3 | |
| 4 | def test_roles_groups_get() -> None: |
| 5 | """Test get endpoint with WireMock""" |
| 6 | test_id = "roles.groups.get.0" |
| 7 | client = get_client(test_id) |
| 8 | client.roles.groups.get( |
| 9 | id="id", |
| 10 | from_="from", |
| 11 | take=1, |
| 12 | ) |
| 13 | verify_request_count(test_id, "GET", "/roles/id/groups", {"from": "from", "take": "1"}, 1) |
| 14 | |
| 15 | |
| 16 | def test_roles_groups_create() -> None: |
| 17 | """Test create endpoint with WireMock""" |
| 18 | test_id = "roles.groups.create.0" |
| 19 | client = get_client(test_id) |
| 20 | client.roles.groups.create( |
| 21 | id="id", |
| 22 | groups=["groups"], |
| 23 | ) |
| 24 | verify_request_count(test_id, "POST", "/roles/id/groups", None, 1) |
| 25 | |
| 26 | |
| 27 | def test_roles_groups_delete() -> None: |
| 28 | """Test delete endpoint with WireMock""" |
| 29 | test_id = "roles.groups.delete.0" |
| 30 | client = get_client(test_id) |
| 31 | client.roles.groups.delete( |
| 32 | id="id", |
| 33 | groups=["groups"], |
| 34 | ) |
| 35 | verify_request_count(test_id, "DELETE", "/roles/id/groups", None, 1) |