(self)
| 16 | cleanup_mock_web_api_server(self) |
| 17 | |
| 18 | def test_users(self): |
| 19 | client = SCIMClient(base_url="http://localhost:8888/", token="xoxp-valid") |
| 20 | client.search_users(start_index=0, count=1) |
| 21 | client.read_user("U111") |
| 22 | |
| 23 | now = str(time.time())[:10] |
| 24 | user = User( |
| 25 | user_name=f"user_{now}", |
| 26 | name=UserName(given_name="Kaz", family_name="Sera"), |
| 27 | emails=[UserEmail(value=f"seratch+{now}@example.com")], |
| 28 | schemas=["urn:scim:schemas:core:1.0"], |
| 29 | ) |
| 30 | client.create_user(user) |
| 31 | # The mock server does not work for PATH requests |
| 32 | try: |
| 33 | client.patch_user("U111", partial_user=User(user_name="foo")) |
| 34 | except: |
| 35 | pass |
| 36 | user.id = "U111" |
| 37 | user.user_name = "updated" |
| 38 | try: |
| 39 | client.update_user(user) |
| 40 | except: |
| 41 | pass |
| 42 | try: |
| 43 | client.delete_user("U111") |
| 44 | except: |
| 45 | pass |
| 46 | |
| 47 | def test_groups(self): |
| 48 | client = SCIMClient(base_url="http://localhost:8888/", token="xoxp-valid") |
nothing calls this directly
no test coverage detected