Skip to content

Commit 3a6180e

Browse files
🧪 update tests
1 parent e8f4892 commit 3a6180e

File tree

2 files changed

+19
-2
lines changed

2 files changed

+19
-2
lines changed

tests/test_app.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,13 @@
66
@pytest.mark.asyncio
77
class TestClient:
88
async def test_basic_usage(self):
9-
app = await client.all_apps()
10-
app = app[0]
9+
app = await client.app('6c8e9b785cce4f99984f9ca1c5470d51')
1110
await app.data()
1211
await app.status()
1312
await app.logs()
1413
await app.backup()
1514
await app.data()
1615
await app.github_integration(GITHUB_ACCESS_TOKEN)
1716
await app.last_deploys()
17+
await app.domain_analytics()
18+
await app.set_custom_domain('test.com.br')

tests/test_request_listeners.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,22 @@ async def test(response: Response):
154154
GITHUB_ACCESS_TOKEN,
155155
)
156156

157+
async def test_domain_analytics(self):
158+
@client.on_request(Endpoint.domain_analytics())
159+
async def test(response: Response):
160+
assert isinstance(response, Response)
161+
162+
await client.domain_analytics('6c8e9b785cce4f99984f9ca1c5470d51')
163+
164+
async def test_set_custom_domain(self):
165+
@client.on_request(Endpoint.custom_domain())
166+
async def test(response: Response):
167+
assert isinstance(response, Response)
168+
169+
await client.set_custom_domain(
170+
'6c8e9b785cce4f99984f9ca1c5470d51', 'test.com.br'
171+
)
172+
157173
async def test_delete_app(self):
158174
@client.on_request(Endpoint.delete_app())
159175
async def test(response: Response):

0 commit comments

Comments
 (0)