3131
3232
3333@pytest .fixture (scope = "session" )
34- def some_domain ():
35- return 'some_domain.test '
34+ def default_domain ():
35+ return 'localhost '
3636
3737
3838@pytest .fixture (scope = "session" )
@@ -46,11 +46,12 @@ def ssl_domain():
4646
4747
4848@pytest_asyncio .fixture (scope = 'session' )
49- def local_http_server (some_domain ) -> Generator [LocalHttpServer , None , None ]:
49+ def local_http_server (
50+ default_domain ) -> Generator [LocalHttpServer , None , None ]:
5051 """
5152 Returns an instance of a LocalHttpServer without SSL pointing to localhost.
5253 """
53- server = LocalHttpServer (default_host = some_domain )
54+ server = LocalHttpServer (default_host = default_domain )
5455 yield server
5556
5657 server .clear ()
@@ -530,11 +531,11 @@ def url_download(file_name="file-name.txt", content="download content"):
530531
531532
532533@pytest .fixture
533- def html (local_http_server , some_domain , another_domain ):
534+ def html (local_http_server , default_domain , another_domain ):
534535 """Return a factory for URL with the given content."""
535- def html (content = "" , same_origin = True ):
536+ def html (content = "" , host = None , same_origin = True ):
536537 if same_origin :
537- return local_http_server .url_200 (host = some_domain , content = content )
538+ return local_http_server .url_200 (host = host , content = content )
538539 else :
539540 return local_http_server .url_200 (host = another_domain ,
540541 content = content )
0 commit comments