Skip to content

Commit

Permalink
Add test-case for server launch
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcTM01 committed Oct 23, 2024
1 parent 797534b commit 3ac2162
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/dataland_qa_lab/bin/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@
logger = logging.getLogger("dataland_qa_lab.bin.server")


def main() -> None:
def main(single_pass_e2e: bool = False) -> None:
"""Launch the QA Lab server."""
console_logger.configure_console_logger()
logger.info("Launching the Dataland QA Lab server")

while True:
logger.info("Still running")
if single_pass_e2e:
break
time.sleep(10)


Expand Down
Empty file added tests/bin/__init__.py
Empty file.
5 changes: 5 additions & 0 deletions tests/bin/test_server.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from dataland_qa_lab.bin import server


def test_server_launch() -> None:
server.main(single_pass_e2e=True)

0 comments on commit 3ac2162

Please sign in to comment.