Skip to content

Commit

Permalink
Test for invalid URL
Browse files Browse the repository at this point in the history
  • Loading branch information
pelletier committed Feb 1, 2024
1 parent d880a20 commit 7136056
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/test_fastapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ def test_configure_no_public_url(self):
with self.assertRaises(ValueError):
dispatch.fastapi.configure(app, api_key="test", public_url="")

def test_configure_public_url_no_scheme(self):
app = fastapi.FastAPI()
with self.assertRaises(ValueError):
dispatch.fastapi.configure(app, api_key="test", public_url="127.0.0.1:9999")

def test_fastapi_simple_request(self):
app = fastapi.FastAPI()
dispatch.fastapi.configure(
Expand Down

0 comments on commit 7136056

Please sign in to comment.