From 57bf00734820f78fcc9602b415f7c892abfd42a4 Mon Sep 17 00:00:00 2001 From: Dou Du Date: Sat, 8 Jun 2024 16:26:36 +0200 Subject: [PATCH] update the test workflow with Element testing --- test/test.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/test.py b/test/test.py index a49339c..632c5b2 100644 --- a/test/test.py +++ b/test/test.py @@ -23,6 +23,13 @@ def setup_method(self, method): def teardown_method(self, method): self.driver.quit() + def test_elements(self): + try: + self.find_element(By.CLASS_NAME, 'element-Si') + print("Element Si is fund!") + else: + raise Exception("Element Si is NOT found!!!") + def download_widget_image(self): self.driver.get("http://localhost:8383/voila/render/example.ipynb") self.driver.set_window_size(1280, 1080) @@ -37,5 +44,6 @@ def download_widget_image(self): test = test_widget() test.setup_method('Chrome') test.download_widget_image() +test.test_elements() test.teardown_method('Chrome')