diff tests/e2e/libervia-web/conftest.py @ 4305:4cd4922de876

tests: reformat tests using black.
author Goffi <goffi@goffi.org>
date Thu, 26 Sep 2024 16:11:56 +0200
parents dfccc90cacc6
children
line wrap: on
line diff
--- a/tests/e2e/libervia-web/conftest.py	Fri Sep 06 18:07:44 2024 +0200
+++ b/tests/e2e/libervia-web/conftest.py	Thu Sep 26 16:11:56 2024 +0200
@@ -49,10 +49,10 @@
     if request.node.rep_setup.passed:
         if request.node.rep_call.failed:
             report_dir = Path(os.getenv("LIBERVIA_TEST_REPORT_DIR", "/tmp/tests_report"))
-            dest_dir = report_dir/"screenshots"
+            dest_dir = report_dir / "screenshots"
             dest_dir.mkdir(parents=True, exist_ok=True)
             filename = f"{datetime.now().isoformat()}_{request.node.name}.png"
-            dest_path = dest_dir/filename
+            dest_path = dest_dir / filename
             helium.get_driver().save_screenshot(str(dest_path))
             print(f" 📸screenshot saved to {dest_path}")
 
@@ -92,6 +92,7 @@
 def nobody_logged_in(browser):
     browser.get_driver().delete_all_cookies()
 
+
 def log_in(browser, account):
     try:
         account_cookies = accounts_cookies[account]
@@ -105,14 +106,17 @@
     else:
         browser.get_driver().add_cookie(account_cookies)
 
+
 @pytest.fixture
 def log_in_account1(browser):
     log_in(browser, "account1")
 
+
 @pytest.fixture
 def log_in_account1_s2(browser):
     log_in(browser, "account1_s2")
 
+
 @pytest.fixture
 def mobile_screen(browser):
     browser.get_driver().set_window_size(*SIZE_MOBILE)