Skip to content

Commit 6054c5e

Browse files
🧪 added tests for LAST_DEPLOYS and GITHUB_INTEGRATION endpoints
1 parent 0e59ffc commit 6054c5e

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

tests/test_request_listeners.py

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
from squarecloud.data import UploadData
66
from squarecloud.http import Response
77

8-
from . import client, create_zip
8+
from . import GITHUB_ACCESS_TOKEN, client, create_zip
99

1010

1111
@pytest.mark.asyncio
@@ -137,6 +137,23 @@ async def test(response: Response):
137137

138138
await client.me()
139139

140+
async def test_last_deploys(self):
141+
@client.on_request(Endpoint.last_deploys())
142+
async def test(response: Response):
143+
assert isinstance(response, Response)
144+
145+
await client.last_deploys(TestRequestListeners.APP_ID)
146+
147+
async def test_github_integration(self):
148+
@client.on_request(Endpoint.github_integration())
149+
async def test(response: Response):
150+
assert isinstance(response, Response)
151+
152+
await client.github_integration(
153+
TestRequestListeners.APP_ID,
154+
GITHUB_ACCESS_TOKEN,
155+
)
156+
140157
async def test_delete_app(self):
141158
@client.on_request(Endpoint.delete_app())
142159
async def test(response: Response):

0 commit comments

Comments
 (0)