Use selenium.browser in test_run_core_python_test

This commit is contained in:
Roman Yurchak 2018-08-20 18:38:01 +03:00
parent f0b9cf1c51
commit 02b61eea62
1 changed files with 3 additions and 3 deletions

View File

@ -285,11 +285,11 @@ def test_open_url(selenium):
@pytest.mark.flaky(reruns=2) @pytest.mark.flaky(reruns=2)
def test_run_core_python_test(python_test, selenium, request): def test_run_core_python_test(python_test, selenium, request):
name, error_flags = python_test name, error_flags = python_test
driver_name = (selenium.__class__.__name__
.replace('Wrapper', '').lower())
if ('crash' in error_flags or if ('crash' in error_flags or
'crash-' + driver_name in error_flags): 'crash-' + selenium.browser in error_flags):
request.applymarker(pytest.mark.xfail( request.applymarker(pytest.mark.xfail(
run=False, reason='known failure with code "{}"' run=False, reason='known failure with code "{}"'
.format(','.join(error_flags)))) .format(','.join(error_flags))))