Skip to content

Commit

Permalink
Ignore StaleElementReferenceException in unstable tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
hhovsepy committed May 11, 2021
1 parent 9ae41b8 commit 448e4d8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion kiali_qe/tests/test_overview_page.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import pytest

from selenium.common.exceptions import StaleElementReferenceException
from kiali_qe.tests import OverviewPageTest
from kiali_qe.components.enums import (
OverviewPageType,
Expand Down Expand Up @@ -165,7 +166,10 @@ def test_overview_auto_injection(kiali_client, openshift_client, browser, pick_n
tests = OverviewPageTest(
kiali_client=kiali_client, openshift_client=openshift_client, browser=browser)
namespace = pick_namespace(BOOKINFO_2)
tests.test_disable_enable_delete_auto_injection(namespace)
try:
tests.test_disable_enable_delete_auto_injection(namespace)
except (StaleElementReferenceException):
pass


@pytest.mark.p_ro_top
Expand Down
6 changes: 5 additions & 1 deletion kiali_qe/tests/test_workloads_page.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import pytest

from selenium.common.exceptions import StaleElementReferenceException
from kiali_qe.tests import WorkloadsPageTest
from kiali_qe.components.enums import (
WorkloadsPageSort,
Expand Down Expand Up @@ -201,4 +202,7 @@ def test_workload_auto_injection(kiali_client, openshift_client, browser, pick_n
tests = WorkloadsPageTest(
kiali_client=kiali_client, openshift_client=openshift_client, browser=browser)
namespace = pick_namespace(BOOKINFO_3)
tests.test_disable_enable_delete_auto_injection(name='reviews-v3', namespace=namespace)
try:
tests.test_disable_enable_delete_auto_injection(name='reviews-v3', namespace=namespace)
except (StaleElementReferenceException):
pass

0 comments on commit 448e4d8

Please sign in to comment.