report.html

Report generated on 06-May-2022 at 23:13:34 by pytest-html v2.1.1

Environment

Packages {"pluggy": "0.13.1", "py": "1.9.0", "pytest": "6.1.0"}
Platform Windows-10-10.0.19041-SP0
Plugins {"allure-pytest": "2.8.18", "datadir": "1.3.1", "html": "2.1.1", "metadata": "1.10.0"}
Python 3.8.5

Summary

153 tests ran in 25981.10 seconds.

73 passed, 0 skipped, 80 failed, 67 errors, 0 expected failures, 0 unexpected passes

Results

Result Test Duration Links
Error test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_PG_user_in_profile_page::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6A948850>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_help_functionality_as_B2B_PG_user_in_program_page::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AC0E640>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_help_functionality_as_B2B_PG_user_in_dashboard_page::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6A8D4580>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_help_functionality_as_B2B_PG_user_in_learning_page::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AC05160>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_help_functionality_as_B2B_PG_user_in_profile_page::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AB51F10>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_create_support_ticket_for_B2C_only_PG_user::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AB77220>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_create_support_ticket_for_B2C_selected_PG_user_if_agent_unavailable::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AC77430>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_connect_agent_for_B2C_selected_PG_user_if_agent_available::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AC5F730>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_connect_agent_for_non_B2C_PG_user_if_agent_available::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6ABE0DC0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_create_support_ticket_for_non_B2C_PG_user_if_agent_unavailable::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6ACB01F0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_course_category_fieldEmpty_for_B2C_only_PG_user::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AC98040>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_category_subCategory_filledUP_for_B2C_only_PG_user::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AD262B0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_help&support.py::TestHelpAndSupport::test_mandatory_fields_to_raise_tickets_for_B2C_only_PG_user::setup 0.00
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AD484C0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_help&support.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_home.py::TestHome::test_search_functionality::setup 0.00
self = <test_home.TestHome object at 0x000001EF6AC14700>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_home.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_home.py::TestHome::test_search_functionality_with_invalid_elearning::setup 0.00
self = <test_home.TestHome object at 0x000001EF6ACC6EE0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_home.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_home.py::TestHome::test_sort_by_a_z::setup 0.00
self = <test_home.TestHome object at 0x000001EF6AABB0A0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_home.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_home.py::TestHome::test_sort_by_z_a::setup 0.00
self = <test_home.TestHome object at 0x000001EF6AACF880>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_home.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_home.py::TestHome::test_sort_by_progress::setup 0.00
self = <test_home.TestHome object at 0x000001EF6A9EA4F0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_home.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_home.py::TestHome::test_sort_by_recent::setup 0.00
self = <test_home.TestHome object at 0x000001EF6AA0F700>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_home.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_unable_update::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6ABC2910>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_lab_present::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6AC2CEB0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_lab_expired::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6AEADEB0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_assessment_expired::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6AECAD00>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_certificate_unlock_logo::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6AB321C0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_notes_avaliable::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6AD003D0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_limited_access.py::TestLimitedAccess::test_access_selflearning::setup 0.00
self = <test_limited_access.TestLimitedAccess object at 0x000001EF6ACF2340>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_limited_access.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_lms_login.py::TestLogin::test_invalid_credentials::setup 0.00
self = <test_lms_login.TestLogin object at 0x000001EF6AD5F550>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_lms_login.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_lms_login.py::TestLogin::test_valid_credentials::setup 0.00
self = <test_lms_login.TestLogin object at 0x000001EF6AD7B790>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_lms_login.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_lms_login.py::TestLogin::test_logout::setup 0.00
self = <test_lms_login.TestLogin object at 0x000001EF6AAEAF10>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_lms_login.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_lms_login.py::TestLogin::test_multiaccount_feature::setup 0.00
self = <test_lms_login.TestLogin object at 0x000001EF6AAEA9A0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_lms_login.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_lms_login.py::TestLogin::test_linkedin_invalid_credentials::setup 0.00
self = <test_lms_login.TestLogin object at 0x000001EF6AE3C7F0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_lms_login.py:15:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_notes.py::TestNotes::test_notes_save::setup 0.00
self = <test_notes.TestNotes object at 0x000001EF6AF5DF10>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_notes.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_notes.py::TestNotes::test_delete_note::setup 0.00
self = <test_notes.TestNotes object at 0x000001EF6AF02250>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_notes.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_notes.py::TestNotes::test_edit_note::setup 0.00
self = <test_notes.TestNotes object at 0x000001EF6AF06460>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_notes.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_notes.py::TestNotes::test_validation_note::setup 0.00
self = <test_notes.TestNotes object at 0x000001EF6AF2F670>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_notes.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_resetpassword.py::TestResetPassword::test_resetpassword_link_verification::setup 0.00
self = <test_resetpassword.TestResetPassword object at 0x000001EF6AFC78B0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_resetpassword.py:18:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_resetpassword.py::TestResetPassword::test_login_with_old_password::setup 0.00
self = <test_resetpassword.TestResetPassword object at 0x000001EF6AD98DC0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_resetpassword.py:18:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_TestData_EngageX_CohortCreation_MultipleSession_WithDifferentDates::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6ADD3730>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_TestData_B2C_LearnerRegistration::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6AE07D90>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_TestData_LMSAdmin_MPAssignment::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B0FC970>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_TestData_B2BEntAdmin_MPAssignment::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B0D7F10>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_TestData_B2B_LearnerRegisteration::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6AFD6130>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_Self_serve_cohort_change_WhenLearnerHasNoProgress_DestinationCohortSelected::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B192250>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_Self_serve_cohort_filter_functionality_in_prefrence_page::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B02B1F0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_CCR_PreferencePage_Calendat_functionality::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B1B2400>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_CCR_WhenLearnerHasNoProgress_Submit_Preference::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B1B1610>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_CCR_EngageX_RejectCCR::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6AFE1D90>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_CCR_EngageX_ApproveCCR::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B0831C0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_selfserve_cohort.py::TestSelfServeCohort::test_Verify_Self_serve_cohort_request_exceed_case::setup 0.00
self = <test_selfserve_cohort.TestSelfServeCohort object at 0x000001EF6B14BFD0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_selfserve_cohort.py:31:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_signup.py::TestSignup::test_signup_existing_user::setup 0.00
self = <test_signup.TestSignup object at 0x000001EF6B12F280>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_signup.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_signup.py::TestSignup::test_signup_functionality::setup 0.00
self = <test_signup.TestSignup object at 0x000001EF6B2B14C0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_signup.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_updatecourse.py::TestUpdateCourse::test_verify_course_name::setup 0.00
self = <test_updatecourse.TestUpdateCourse object at 0x000001EF6B2B3760>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_updatecourse.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_updatecourse.py::TestUpdateCourse::test_reject_update::setup 0.00
self = <test_updatecourse.TestUpdateCourse object at 0x000001EF6B2FB940>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_updatecourse.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_updatecourse.py::TestUpdateCourse::test_redirect_updatepage::setup 0.00
self = <test_updatecourse.TestUpdateCourse object at 0x000001EF6B06DE20>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_updatecourse.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_updatecourse.py::TestUpdateCourse::test_update_on_coursecard::setup 0.00
self = <test_updatecourse.TestUpdateCourse object at 0x000001EF6B2F90A0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_updatecourse.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_user_account.py::TestUserAccount::test_uneditable_email_username::setup 0.02
self = <test_user_account.TestUserAccount object at 0x000001EF6B389FA0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_user_account.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_user_account.py::TestUserAccount::test_profile_verification::setup 0.00
self = <test_user_account.TestUserAccount object at 0x000001EF6B25E1F0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_user_account.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_user_account.py::TestUserAccount::test_edit_profile::setup 0.00
self = <test_user_account.TestUserAccount object at 0x000001EF6B186040>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_user_account.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_visit_verb::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B3F02E0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_learningtime_verb_check_for_already_watched_video::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B31E340>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_videolearning_verb_check_for_already_watched_video::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B45E730>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_learningtime_verb_check_for_new_video::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B478760>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_videolearning_verb_check_for_new_video::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B275F40>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_class_registration_policy::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B37C100>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_register_verb::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B391D00>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_unregister_verb::setup 0.00
self = <test_verbs.TestVerbs object at 0x000001EF6B0A31C0>, scope = 'class'

@pytest.fixture
def initialize_pages(self,scope='class'):
> self.pg_login = LoginPage(pytest.driver)

test\test_verbs.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\login_page.py:14: in __init__
self.driver.maximize_window()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:737: in maximize_window
self.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Error test_verbs.py::TestVerbs::test_unregister_verb::teardown 0.05
self = <allure_commons._allure.fixture object at 0x000001EF66F29520>, args = (), kwargs = {}

def __call__(self, *args, **kwargs):
self.parameters = func_parameters(self._fixture_function, *args, **kwargs)

with self:
> return self._fixture_function(*args, **kwargs)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\allure_commons\_allure.py:185:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
test\conftest.py:102: in setup
pytest.driver.close()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:688: in close
self.execute(Command.CLOSE)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyCourseProgress_OSLProgress 123.60
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF67A7B1C0>, initialize_pages = None
testdata = {'Core_java_syllabus_url': '/courses/3004/Core-Java/syllabus', 'bigdata_hadoop_syllabus_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus', 'course_url': '/courses', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T16844","high","LMS Regression","Pradeep")
def test_LMS_VerifyCourseProgress_OSLProgress(self,initialize_pages,testdata):

'''
Objective : This test it to verify the osl progress is working fine.

Step 01: Execute the test case
Step 02: Navigate to the course
Step 03: capture the osl progress on the course card
Step 04: click on course card
Step 05: capture the oslprogress on top of the page
Step 06: play the videos
Step 07: once the video is finished, verify the progress bar on the video
Step 08: finish all the videos and verify the osl progress on top of the card
Step 09: Click on back button
Step 10: capture the osl progress on the course card
Step 11: verify the same in DB

'''

#Step 01: Execute the test case
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['learner_classic_master']
mp_cohort=data['testdata_for_lms_regression']['MP_cohort']
logging.info("test data Loaded")

pytest.driver.delete_all_cookies()
lms_login_helper.new_b2c_login(email_id,testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['home_url'])
#time.sleep(20)
selenium_helper.wait_for_page_to_load(20,testdata['onboarding_url'])
# Incase user redirected to oob form page , then need to fill the form and then continue
if testdata['onboarding_url'] in pytest.driver.current_url:
logging.info("unser landed on Onboarding Page")
self.pg_onboarding.onboardfill()

#time.sleep(20)
selenium_helper.wait_for_page_to_load(60,testdata['dashboard_url'])
if selenium_helper.is_element_present(self.pg_assignment.locators["button_got_it"][0],5):
logging.info("community popup notification appeared gor new learner")
self.pg_assignment.button_got_it.click_button()

if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()

#self.pg_lms.check_program_tile_mp()

#Step 02: Navigate to the course
self.pg_lms.click_startProgram()
selenium_helper.wait_for_page_to_load(30,testdata['course_url'])

#Verify the courses under courses tab
courses = self.pg_lms.check_courses_under_CoursesTab()

#Step 03: capture the osl progress on the course card
osl_progrss_onCard = self.pg_lms.all_courses_completion_percentage()

#Step 04: click on course card
self.pg_certificate.btn_back_to_master_program.click()
logging.info("clicked on Back Button on courses")
#time.sleep(10)
selenium_helper.wait_for_page_to_load(60,testdata['dashboard_url'])

self.pg_certificate.goToSupportAssign(testdata['Core_java_syllabus_url'])
#time.sleep(20)
selenium_helper.wait_for_page_to_load(120,testdata['Core_java_syllabus_url'])
#time.sleep(200)
#Step 05: capture the oslprogress on top of the page
cource_completion_onTop = self.pg_lms.pertentage_on_top()
logging.info(f"{cource_completion_onTop}% completion Captured on Top")

#Step 06: play the videos
#Step 07: once the video is finished, verify the progress bar on the video
#Step 08: finish all the videos and verify the osl progress on top of the card
> percentage_completion = self.pg_lms.watch_videos()

test\test_LMS_Regression_Test.py:974:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\lms_page.py:247: in watch_videos
lesson.click()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element is not clickable at point (450, 1121)
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:923 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 Big Data Hadoop and Spark Developer : course present in courses tab INFO  setup:lms_page.py:50 Lean Management : course present in courses tab INFO  setup:lms_page.py:50 Core Java : course present in courses tab INFO  setup:lms_page.py:96 Big Data Hadoop and Spark Developer : 0% INFO  setup:lms_page.py:96 Lean Management : 0% INFO  setup:lms_page.py:96 Core Java : 0% INFO  setup:test_LMS_Regression_Test.py:959 clicked on Back Button on courses INFO  setup:test_LMS_Regression_Test.py:969 0% completion Captured on Top ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/3004/Core-Java/syllabus is not present INFO  setup:lms_page.py:244 Total no of lesson : 14
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_ForExistingB2CLearners 65.57
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68544B80>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_certificationprogram': 'Certification Programs', 'b2b_url': '/apachedev/git/paperclip/public/affiliate', 'confirm_password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T16859","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_ForExistingB2CLearners(self,initialize_pages,testdata):

'''
Objective : This test is to verify the assignment from B2B portal for the existing b2c learner.

Step 01: LMSAdmin_MPAssignment_ClassicMaster
Step 02: B2B Assignment for existing learner

'''
#Step 01: Execute the test case
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['learner_classic_master']
logging.info("test data Loaded")

pytest.driver.delete_all_cookies()

#Step 02: B2B Assignment for existing learner
lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
#time.sleep(5)
logging.info("logged in to xenia successfull..!!")
selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()
selenium_helper.wait_for_page_to_load(10,testdata['redirecton_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:1901:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF68677430>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1889 test data Loaded WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:1897 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_MultiAccountLoginPage 89.48
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68544F10>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'home_url': '/dashboard', 'multi_acc_url': 'multi-account', 'onboarding_url': '/oob/onboarding', ...}

@pytest.mark.test_details("SLUB-T16860","high","LMS Regression","Pradeep")
def test_Verify_MultiAccountLoginPage(self,initialize_pages,testdata):

'''
Objective : This test is to verify the assignment from B2B portal for the existing b2c learner.

Step 01: LMSAdmin_MPAssignment_ClassicMaster
Step 02: B2B Assignment for existing learner

'''
#Step 01: Execute the test case
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['learner_classic_master']
logging.info("test data Loaded")
logging.info(email_id)

pytest.driver.delete_all_cookies()
lms_login_helper.loging_multi_acc(email_id,testdata['password'])

if testdata['dashboard_url'] in pytest.driver.current_url:
time.sleep(5)
logging.info("logging out Learner")
self.pg_certificate.btn_logout_dropdown.click_button()
self.pg_certificate.btn_logout.click_button()
time.sleep(25)
logging.info("Logout successfully")
lms_login_helper.loging_multi_acc(email_id,testdata['password'])
pytest.driver.delete_all_cookies()



> assert (testdata['multi_acc_url'] in pytest.driver.current_url)
E assert 'multi-account' in 'http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard'
E + where 'http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard' = <selenium.webdriver.chrome.webdriver.WebDriver (session="9b3a21781391fdbf94e369f7b18da6d3")>.current_url
E + where <selenium.webdriver.chrome.webdriver.WebDriver (session="9b3a21781391fdbf94e369f7b18da6d3")> = pytest.driver

test\test_LMS_Regression_Test.py:1966: AssertionError
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1948 test data Loaded INFO  setup:test_LMS_Regression_Test.py:1949 irisregression7420@yopmail.com INFO  setup:test_LMS_Regression_Test.py:1956 logging out Learner INFO  setup:test_LMS_Regression_Test.py:1960 Logout successfully
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_SelfServeCohort 232.54
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF685FCBB0>, initialize_pages = None
testdata = {'cohort_change_success_message': 'Cohort Changed Successfully', 'cohort_change_url': '/ss-cohort-change', 'cohort_home_url': '/dashboard', 'db_type': 'mysql', ...}

@pytest.mark.test_details("SLUB-T16682","high","LMS Regression","pradeep")
def test_SelfServeCohort(self,initialize_pages,testdata):
'''
Objective: Verify Self-serve cohort change When Learner Has No Progress Destination Cohort Selected

Step 01: Login as learner
Step 02: Click on Change Cohort
Step 03: From the preference page select cohort
Step 04: Give reason for cohort change
Step 05: Submit request
Step 06: Verify successful page 1.old cohort name/2. new cohort name
Step 07: Click on back to dash board page - new cohort should display
Step 08: avail of cohort request should change 1 to 2
Step 09: Engaex Verification 1. Go to old cohort/2. In cohort change tab - > aprrove tab -> learner should present
Step 10 Mysql Verification 1. Cohort_change_request table - active_cohort_id should be new cohort id/2. learnerprogram tablle active cohort id should new cohort id

'''
#read data from CCR_test_data.json file
json_data=json.load(open('LMS_regression_testdata.json','r'))
email_id=json_data['testdata_for_lms_regression']['learner_cohort_master']
cohort=json_data['testdata_for_lms_regression']['MP_cohort']

#Step 01: Login as learner
lms_login_helper.new_b2c_login(email_id,testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['home_url'])
time.sleep(20)
# Incase user redirected to oob form page , then need to fill the form and then continue
if testdata['onboarding_url'] in pytest.driver.current_url:
self.pg_onboarding.onboardfill()

time.sleep(20)
if selenium_helper.is_element_present(self.pg_assignment.locators["button_got_it"][0],10):
self.pg_assignment.button_got_it.click_button()
if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()

#Step 02: Click on Change Cohort
if selenium_helper.is_element_present(self.pg_certificate.locators['tab_master_program'][0],60) == True:
time.sleep(5)
self.pg_certificate.tab_master_program.click_button()
time.sleep(20)

self.pg_cohort.click_change_cohort()
time.sleep(2)
selenium_helper.wait_for_page_to_load(60,testdata['cohort_change_url'])

avail_cohort_count_before=self.pg_cohort.avail_cohort_count()
#Step 03: From the preference page select cohort
> new_assigned_cohort = self.pg_cohort.select_random_join_cohort()

test\test_LMS_Regression_Test.py:2523:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\cohorts_page.py:809: in select_random_join_cohort
self.arrow_show_more_cohort.scroll_to_element()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.cohorts_page.CohortsPage object at 0x000001EF6808B820>, loc = 'arrow_show_more_cohort'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: arrow_show_more_cohort

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:cohorts_page.py:571 clicked on change cohort ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//*[@class='show-block ng-star-inserted']//span)") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/ss-cohort-change is not present WARNING  setup:page_factory.py:57 the locator arrow_show_more_cohort on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/ss-cohort-change is not present WARNING  setup:page_factory.py:57 the locator arrow_show_more_cohort on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/ss-cohort-change is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_CohortChangeRequest_WithoutSelfServe 301.26
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF6808B3A0>, initialize_pages = None
testdata = {'cohort_change_success_message': 'Cohort Changed Successfully', 'cohort_change_url': '/ss-cohort-change', 'cohort_home_url': '/dashboard', 'db_type': 'mysql', ...}

@pytest.mark.test_details("SLUB-T16683","high","LMS Regression","pradeep")
def test_CohortChangeRequest_WithoutSelfServe(self,initialize_pages,testdata):

'''
Objective: Verify submit_preferences cohort change When Learner Has No Progress Destination Cohort Selected

Step 01: Login as learner
Step 02: Click on Change Cohort
Step 03: From the preference page select submit preferences
Step 04: Give reason for cohort change
Step 05: Submit request
Step 06: Verify successful page 1.old cohort name/2. new cohort name
Step 07: Click on back to dash board page - new cohort should display
Step 08: avail of cohort request should change 1 to 2
Step 09: Engaex Verification 1. Go to old cohort/2. In cohort change tab - > aprrove tab -> learner should present
Step 10 Mysql Verification 1. Cohort_change_request table - active_cohort_id should be new cohort id/2. learnerprogram tablle active cohort id should new cohort id

'''

json_data=json.load(open('LMS_regression_testdata.json','r'))
email_id=json_data['testdata_for_lms_regression']['learner_cohort_master']
#cohort=json_data['testdata_for_lms_regression']['MP_cohort']

lms_login_helper.new_b2c_login(email_id,testdata['password'])
time.sleep(10)
selenium_helper.wait_for_page_to_load(60,testdata['home_url'])
time.sleep(20)
# Incase user redirected to oob form page , then need to fill the form and then continue
if testdata['onboarding_url'] in pytest.driver.current_url:
self.pg_onboarding.onboardfill()

time.sleep(20)
if selenium_helper.is_element_present(self.pg_assignment.locators["button_got_it"][0],10):
self.pg_assignment.button_got_it.click_button()
if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()

if selenium_helper.is_element_present(self.pg_certificate.locators['tab_master_program'][0],60) == True:
time.sleep(5)
self.pg_certificate.tab_master_program.click_button()
time.sleep(20)

cohort = self.pg_cohort.cohort_name_in_dashboard.get_text()
logging.info(f"Cohort in learner Dashboard : {cohort}")

#Step 04: Click on Change Cohort
self.pg_cohort.click_change_cohort()
time.sleep(2)
selenium_helper.wait_for_page_to_load(60,testdata['cohort_change_url'])

#Step 05: submit preferences selected
> self.pg_cohort.click_show_more_cohort()

test\test_LMS_Regression_Test.py:2644:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\cohorts_page.py:637: in click_show_more_cohort
self.arrow_show_more_cohort.scroll_to_element()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.cohorts_page.CohortsPage object at 0x000001EF6808B610>, loc = 'arrow_show_more_cohort'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: arrow_show_more_cohort

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_LMS_Regression_Test.py:2636 Cohort in learner Dashboard : MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression INFO  setup:cohorts_page.py:571 clicked on change cohort WARNING  setup:page_factory.py:57 the locator arrow_show_more_cohort on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/ss-cohort-change is not present WARNING  setup:page_factory.py:57 the locator arrow_show_more_cohort on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/ss-cohort-change is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_B2C_NewUser_SinglePurchase_Seamless 187.87
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF687C6070>, initialize_pages = None
testdata = {'asm': '/agile-and-scrum', 'card_name': 'simplilearn', 'coupon_code': 'test99-lp1', 'credit_number': '4111 1111 1111 1111', ...}

@pytest.mark.test_details("SLUB-T16684","high","LMS Regression","pradeep")
def test_B2C_NewUser_SinglePurchase_Seamless(self,initialize_pages,testdata):

'''
Objective: To check the purchase flow for a new user purchasing a single product from the website via seamless payment.

Step 01: Purchase a single product for a new user from the website.
Step 02: Vertify end to end order purchase flow.
'''
pytest.driver.delete_all_cookies()
email_id = TestLMSRegression.create_newUser_(self,testdata)
logging.info("Neaw Learner Created Successfully")
logging.info(f"The leaner registered is : {email_id}")
time.sleep(10)

#dump data for future use
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
data['testdata_for_lms_regression']['learner_seamless_purchase']=email_id

with open("LMS_regression_testdata.json",'w') as file:
json.dump(data,file,indent=4)

lms_login_helper.new_b2c_login(email_id,testdata['password'])
logging.info(f"learner logged in with email : {email_id}")
if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()
lms_login_helper.loging_agile_and_scrum()
selenium_helper.wait_for_page_to_load(30,testdata['asm'])
logging.info("learner REdirected to Agile and Scrum page")

utils.set_locatori9_cookie()
self.pg_lms.select_ASM()
> self.pg_lms.generate_payment_india(email_id,testdata['credit_number'],testdata['card_name'],testdata['coupon_code'])

test\test_LMS_Regression_Test.py:2719:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\lms_page.py:501: in generate_payment_india
self.revx_page.proceed_btn.click_button()
core\page_factory.py:195: in click_button
self.click()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <button type="button" class="btn btn-warning summary-btn" ng-click="collapseCourseSummary($event);fetchNetBankingPrefrences($event);createPaymentOrder('bde6a1cf2a9f8c4a54f037569dec5d096f7b39374c82f6771cc4811f263aef52');loginSplitit('bde6a1cf2a9f8c4a54f037569dec5d096f7b39374c82f6771cc4811f263aef52');" ng-mobile-click="collapseCourseSummary($event);fetchNetBankingPrefrences($event);createPaymentOrder('bde6a1cf2a9f8c4a54f037569dec5d096f7b39374c82f6771cc4811f263aef52');loginSplitit('bde6a1cf2a9f8c4a54f037569dec5d096f7b39374c82f6771cc4811f263aef52');" ng-disabled="!generalDetails.grand_total &amp;&amp; generalDetails.is_bajaj_finserv" ng-class="{'disabled': !generalDetails.grand_total &amp;&amp; generalDetails.is_bajaj_finserv}">...</button> is not clickable at point (1306, 579). Other element would receive the click: <div class="popup_country_wrapper cart_overlay" ng-style="{'display':(isRequestPending === 1) ? 'block' : 'none'}" style="display: block;">...</div>
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:108 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:108 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:108 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:108 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:108 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:2696 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:2697 The leaner registered is : iris_regression6135@yopmail.com INFO  setup:test_LMS_Regression_Test.py:2709 learner logged in with email : iris_regression6135@yopmail.com ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_LMS_Regression_Test.py:2715 learner REdirected to Agile and Scrum page INFO  setup:utils.py:53 COOKIES ############# : {'name': 'locatori9', 'value': '%7B%22city_id%22%3A%2247%22%2C%22country_id%22%3A%226%22%2C%22region_name%22%3A%22Karnataka%22%2C%22name%22%3A%22Bangalore%22%2C%22status%22%3A%221%22%2C%22longitude%22%3A%2212.976230%22%2C%22latitude%22%3A%2277.603290%22%2C%22location_time_zone%22%3A%22Asia%5C%2FKolkata%22%2C%22isUpdate%22%3Atrue%2C%22callingCode%22%3A%2291%22%2C%22countryCode%22%3A%22IN%22%2C%22countryTimeZone%22%3A%22Asia%5C%2FKolkata%22%2C%22country_name%22%3A%22India%22%2C%22currency_id%22%3A%221%22%2C%22symbol%22%3A%22Rs.%22%2C%22currency_code%22%3A%22INR%22%2C%22world_region%22%3A%22INR%22%2C%22support_number%22%3A%221800-212-7688%22%2C%22clickToCallNumber%22%3A%221800-212-7688%22%2C%22isTollFree%22%3A%221%22%2C%22cdnCountry%22%3A%22IN%22%7D', 'expires': '2022-05-09T12:30:14.663419Z', 'path': '/', 'domain': '.simplilearn.com', 'SameSite': 'Lax'} INFO  setup:lms_page.py:463 Agile Scrum Master is Selected
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_B2C_ReturningUser_SinglePurchase_Seamless 503.84
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68DEFBB0>, initialize_pages = None
testdata = {'asm': '/agile-and-scrum', 'card_name': 'simplilearn', 'coupon_code': 'test99-lp1', 'credit_number': '4111 1111 1111 1111', ...}

@pytest.mark.test_details("SLUB-T16686","high","LMS Regression","pradeep")
def test_B2C_ReturningUser_SinglePurchase_Seamless(self,initialize_pages,testdata):

'''
Objective: To check the purchase flow for an old user purchasing a single product from the website via seamless payment.

Step 01: Purchase a single product for an old user from the website.
Step 02: Vertify end to end order purchase flow.
'''
pytest.driver.delete_all_cookies()

#read data from Json File
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['learner_seamless_purchase']

lms_login_helper.new_b2c_login(email_id,testdata['password'])
time.sleep(10)
logging.info(f"learner logged in with email : {email_id}")
if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()
lms_login_helper.loging_agile_and_scrum()
selenium_helper.wait_for_page_to_load(30,testdata['asm'])
logging.info("learner REdirected to Agile and Scrum page")

utils.set_locatori9_cookie()
self.pg_lms.select_PMI_ACP()
self.pg_lms.generate_payment_india(email_id,testdata['credit_number'],testdata['card_name'],testdata['coupon_code'])

time.sleep(10)
self.pg_revx.btn_go_to_myCourses.click()
logging.info("clicked on Go TO My Courses Button")
time.sleep(20)

lms_login_helper.new_b2c_login(email_id,testdata['password'])
time.sleep(30)

# Incase user redirected to oob form page , then need to fill the form and then continue
if testdata['onboarding_url'] in pytest.driver.current_url:
self.pg_onboarding.onboardfill_for_CPL(email_id)

time.sleep(20)
if selenium_helper.is_element_present(self.pg_assignment.locators["button_got_it"][0],10):
> self.pg_assignment.button_got_it.click_button()

test\test_LMS_Regression_Test.py:2799:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
core\page_factory.py:195: in click_button
self.click()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <button _ngcontent-dpi-c44="" class="joyride-button" ng-reflect-ng-style="[object Object]" style="background-color: rgb(59, 85, 96); color: rgb(255, 255, 255); border-color: transparent;">...</button> is not clickable at point (731, 669). Other element would receive the click: <path fill="rgb(82,170,243)" fill-opacity="1" d=" M480.97149658203125,-326.70050048828125 C480.97149658203125,-326.70050048828125 480.97149658203125,326.70050048828125 480.97149658203125,326.70050048828125 C480.97149658203125,326.70050048828125 -480.97149658203125,326.70050048828125 -480.97149658203125,326.70050048828125 C-480.97149658203125,326.70050048828125 -480.97149658203125,-326.70050048828125 -480.97149658203125,-326.70050048828125 C-480.97149658203125,-326.70050048828125 480.97149658203125,-326.70050048828125 480.97149658203125,-326.70050048828125z"></path>
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2773 learner logged in with email : iris_regression6135@yopmail.com ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_LMS_Regression_Test.py:2779 learner REdirected to Agile and Scrum page INFO  setup:utils.py:53 COOKIES ############# : {'name': 'locatori9', 'value': '%7B%22city_id%22%3A%2247%22%2C%22country_id%22%3A%226%22%2C%22region_name%22%3A%22Karnataka%22%2C%22name%22%3A%22Bangalore%22%2C%22status%22%3A%221%22%2C%22longitude%22%3A%2212.976230%22%2C%22latitude%22%3A%2277.603290%22%2C%22location_time_zone%22%3A%22Asia%5C%2FKolkata%22%2C%22isUpdate%22%3Atrue%2C%22callingCode%22%3A%2291%22%2C%22countryCode%22%3A%22IN%22%2C%22countryTimeZone%22%3A%22Asia%5C%2FKolkata%22%2C%22country_name%22%3A%22India%22%2C%22currency_id%22%3A%221%22%2C%22symbol%22%3A%22Rs.%22%2C%22currency_code%22%3A%22INR%22%2C%22world_region%22%3A%22INR%22%2C%22support_number%22%3A%221800-212-7688%22%2C%22clickToCallNumber%22%3A%221800-212-7688%22%2C%22isTollFree%22%3A%221%22%2C%22cdnCountry%22%3A%22IN%22%7D', 'expires': '2022-05-09T12:31:45.515713Z', 'path': '/', 'domain': '.simplilearn.com', 'SameSite': 'Lax'} INFO  setup:lms_page.py:480 PMI-ACP® Certification is Selected INFO  setup:lms_page.py:502 Clicked on Proceed Button in First Step INFO  setup:lms_page.py:505 email set to : iris_regression6135@yopmail.com INFO  setup:lms_page.py:514 clicked on Proceed Button on Second Step WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv5.simplilearn.com:8561/apachedev/git/ice9/frontend/public/cart/completed?authtoken=4556bef284876bafa6d3f2d6aecfbdee593eb511acb9e7faf25083c1aaa78919&authorization=success is not present INFO  setup:lms_page.py:532 order_number_idSMPL_DVS7TKWB1IR INFO  setup:test_LMS_Regression_Test.py:2787 clicked on Go TO My Courses Button
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_B2C_NewUser_SinglePurchase_CPL 619.10
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68DF6730>, initialize_pages = None
testdata = {'asm': '/agile-and-scrum', 'card_name': 'simplilearn', 'credit_number': '4111 1111 1111 1111', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T16685","high","LMS Regression","pradeep")
def test_B2C_NewUser_SinglePurchase_CPL(self,initialize_pages,testdata):

'''
Objective: To check the purchase flow for a new user purchasing a single product from RevX via CPL creation.

Step 01: Purchase a single product for a new user via RevX.
Step 02: Vertify end to end order purchase flow.
'''

email_id = utils.generate_random_email_regression_()
name = testdata['name']
last_name = "testlastname"
logging.info(f"email id id : {email_id}")
#dump data for future use
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
data['testdata_for_lms_regression']['learner_CPL_single_course']=email_id

with open("LMS_regression_testdata.json",'w') as file:
json.dump(data,file,indent=4)

pytest.driver.delete_all_cookies()

salesforce_login_helper.sf_login()
# Creating the order/Generating the order for regular
revx_helper.create_payment_single_course(testdata['payment_details'],email_id)

# Verifying the Payment Generate Link Message
revx_helper.verify_custom_link_message(email_id)

#logout from revx
logging.info("logging out From REVX")
self.pg_revx.logout.click()
time.sleep(10)
logging.info("logout from RevX success")

#Get payment link From mail box
pytest.driver.delete_all_cookies()
pytest.driver.get(pytest.config['yopmail_url'])
logging.info("yopmail URL Opened")
time.sleep(5)
self.pg_assignment.yopmail_mail_login(email_id)
logging.info("logged in to Yopmail")
pytest.driver.switch_to.frame(self.pg_assignment.yopmail_iframe_message)

default_handle = pytest.driver.current_window_handle
if selenium_helper.is_element_present(self.pg_assignment.locators['payment_link'][0],5) == True:
self.pg_assignment.payment_link.click()
logging.info("CLicked on Payment link in Yopmail")
time.sleep(5)
handles = list(pytest.driver.window_handles)
for handle_check_counter in range(1,10):
if len(handles) >1:
pytest.driver.close()
pytest.driver.switch_to.window(handles[1])
break

#Make Payment
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
time.sleep(10)
logging.info("payment page opened")
self.pg_lms.generate_payment(name,email_id)
logging.info("payment done Successfully")

time.sleep(10)
self.pg_revx.btn_go_to_myCourses.click()
logging.info("clicked on Register Learner Button")
time.sleep(30)

#Register Learner
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
logging.info("registering Learner")
self.pg_signup.txt_lastname.set_text(last_name)
self.pg_signup.txt_password.set_text(testdata['password'])
self.pg_signup.verify_checkbox_selected()
self.pg_signup.btn_signup.click_button()
logging.info("learner Registration Success")

time.sleep(25)
lms_login_helper.new_b2c_login(email_id,testdata['password'])
# Incase user redirected to oob form page , then need to fill the form and then continue
time.sleep(30)
if testdata['onboarding_url'] in pytest.driver.current_url:
logging.info("landed on Obb Form")
self.pg_onboarding.onboardfill_for_CPL(email_id)

time.sleep(20)
logging.info("learner landed on Dashboard")

for iterator in range(0,3):
if selenium_helper.is_element_present(self.pg_assignment.locators['button_got_it'][0],60) == True:
time.sleep(2)
> self.pg_assignment.button_got_it.click()

test\test_LMS_Regression_Test.py:2918:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <button _ngcontent-vym-c40="" class="joyride-button" ng-reflect-ng-style="[object Object]" style="background-color: rgb(59, 85, 96); color: rgb(255, 255, 255); border-color: transparent;">...</button> is not clickable at point (731, 669). Other element would receive the click: <path fill="rgb(82,170,243)" fill-opacity="1" d=" M480.97149658203125,-326.70050048828125 C480.97149658203125,-326.70050048828125 480.97149658203125,326.70050048828125 480.97149658203125,326.70050048828125 C480.97149658203125,326.70050048828125 -480.97149658203125,326.70050048828125 -480.97149658203125,326.70050048828125 C-480.97149658203125,326.70050048828125 -480.97149658203125,-326.70050048828125 -480.97149658203125,-326.70050048828125 C-480.97149658203125,-326.70050048828125 480.97149658203125,-326.70050048828125 480.97149658203125,-326.70050048828125z"></path>
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2838 email id id : iris_regression6228@yopmail.com WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8087/apachedev/git/ice9/backend/public/sso/payment is not present INFO  setup:revx_helper.py:45 changing docker to 8085 INFO  setup:revx_helper.py:106 Adding Product INFO  setup:revx_helper.py:467 payment link generated is : Following link has been sent to your customer: Payment link: http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=755af75563b5c8d1af16ceb588e2b7fb01e5574c5ecf46e86a6a395e4b6f3aee INFO  setup:test_LMS_Regression_Test.py:2857 logging out From REVX INFO  setup:test_LMS_Regression_Test.py:2860 logout from RevX success INFO  setup:test_LMS_Regression_Test.py:2865 yopmail URL Opened INFO  setup:assignment_page.py:138 The email used for yopmail login is : iris_regression6228@yopmail.com INFO  setup:test_LMS_Regression_Test.py:2868 logged in to Yopmail INFO  setup:test_LMS_Regression_Test.py:2874 CLicked on Payment link in Yopmail INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=755af75563b5c8d1af16ceb588e2b7fb01e5574c5ecf46e86a6a395e4b6f3aee INFO  setup:test_LMS_Regression_Test.py:2886 payment page opened WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8085/apachedev/git/ice9/frontend/public/cart/completed?authtoken=755af75563b5c8d1af16ceb588e2b7fb01e5574c5ecf46e86a6a395e4b6f3aee&authorization=success is not present INFO  setup:lms_page.py:600 order_number_idCSTM_DNUJ8XCJNOQ INFO  setup:test_LMS_Regression_Test.py:2888 payment done Successfully INFO  setup:test_LMS_Regression_Test.py:2892 clicked on Register Learner Button INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression6228@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage INFO  setup:test_LMS_Regression_Test.py:2897 registering Learner WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression6228@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression6228@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression6228@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not visible WARNING  setup:page_factory.py:57 the locator btn_signup on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression6228@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not present INFO  setup:test_LMS_Regression_Test.py:2902 learner Registration Success INFO  setup:test_LMS_Regression_Test.py:2913 learner landed on Dashboard
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_B2C_ReturningUser_SinglePurchase_CPL 420.12
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68DEFDF0>, initialize_pages = None
testdata = {'asm': '/agile-and-scrum', 'card_name': 'simplilearn', 'credit_number': '4111 1111 1111 1111', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T16687","high","LMS Regression","pradeep")
def test_B2C_ReturningUser_SinglePurchase_CPL(self,initialize_pages,testdata):

'''
Objective: To check the purchase flow for a Existing learner purchasing a single product from RevX via CPL creation.

Step 01: Purchase a single product for a existing user via RevX.
Step 02: Vertify end to end order purchase flow.
'''

with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['learner_CPL_single_course']
name = testdata['name']

logging.info("test data Loaded")
pytest.driver.delete_all_cookies()

salesforce_login_helper.sf_login()
# Creating the order/Generating the order for regular
revx_helper.create_payment_single_course_second_time(testdata['payment_details'],email_id)

# Verifying the Payment Generate Link Message
revx_helper.verify_custom_link_message(email_id)

#logout from revx
logging.info("logging out From REVX")
self.pg_revx.logout.click()
time.sleep(10)
logging.info("logout from RevX success")

#Get payment link From mail box
pytest.driver.delete_all_cookies()
pytest.driver.get(pytest.config['yopmail_url'])
logging.info("yopmail URL Opened")
time.sleep(5)
self.pg_assignment.yopmail_mail_login(email_id)
logging.info("logged in to Yopmail")
pytest.driver.switch_to.frame(self.pg_assignment.yopmail_iframe_message)

default_handle = pytest.driver.current_window_handle
if selenium_helper.is_element_present(self.pg_assignment.locators['payment_link'][0],5) == True:
self.pg_assignment.payment_link.click()
logging.info("CLicked on Payment link in Yopmail")
time.sleep(5)
handles = list(pytest.driver.window_handles)
for handle_check_counter in range(1,10):
if len(handles) >1:
pytest.driver.close()
pytest.driver.switch_to.window(handles[1])
break

#Make Payment
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
time.sleep(10)
logging.info("paymenr page opened")
self.pg_lms.generate_payment(name,email_id)
logging.info("payment done Successfully")

time.sleep(10)
self.pg_revx.btn_go_to_myCourses.click()
logging.info("clicked on Register Learner Button")
time.sleep(20)

#login Learner
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])

logging.info("Logging in Learner")
lms_login_helper.new_b2c_login(email_id,testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
logging.info("learner Login Success")
if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()

selenium_helper.is_element_present(self.pg_lms.locators['agile_scrum_master'][0],60)
time.sleep(3)
all_courses = self.pg_lms.agile_scrum_master.get_all_elements()
logging.info(f"Total Courses Purchased : {len(all_courses)}")
for course in all_courses:
logging.info(f"course purchased is : {course.text}")

#logout as learner
logging.info("Logging out Learner")
time.sleep(2)
> self.pg_assignment.btn_logout_dropdown.click_button()

test\test_LMS_Regression_Test.py:3024:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
core\page_factory.py:195: in click_button
self.click()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <span _ngcontent-jro-c3="" class="profile-img">...</span> is not clickable at point (1494, 40). Other element would receive the click: <div class="joyride-backdrop backdrop-right" style="width: 100%; background-color: rgba(59, 85, 96, 0.7);"></div>
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2954 test data Loaded WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8087/apachedev/git/ice9/backend/public/sso/payment is not present INFO  setup:revx_helper.py:146 changing docker to 8085 INFO  setup:revx_helper.py:207 Adding Product INFO  setup:revx_helper.py:467 payment link generated is : Following link has been sent to your customer: Payment link: http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=c5eab0064946fd7994ad911bbbc2ac4859daec43dc463d0098eb3ffcefe0c13d INFO  setup:test_LMS_Regression_Test.py:2965 logging out From REVX INFO  setup:test_LMS_Regression_Test.py:2968 logout from RevX success INFO  setup:test_LMS_Regression_Test.py:2973 yopmail URL Opened INFO  setup:assignment_page.py:138 The email used for yopmail login is : iris_regression6228@yopmail.com INFO  setup:test_LMS_Regression_Test.py:2976 logged in to Yopmail INFO  setup:test_LMS_Regression_Test.py:2982 CLicked on Payment link in Yopmail INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=c5eab0064946fd7994ad911bbbc2ac4859daec43dc463d0098eb3ffcefe0c13d INFO  setup:test_LMS_Regression_Test.py:2994 paymenr page opened WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8085/apachedev/git/ice9/frontend/public/cart/completed?authtoken=c5eab0064946fd7994ad911bbbc2ac4859daec43dc463d0098eb3ffcefe0c13d&authorization=success is not present INFO  setup:lms_page.py:600 order_number_idCSTM_2QQX15Z53RI INFO  setup:test_LMS_Regression_Test.py:2996 payment done Successfully INFO  setup:test_LMS_Regression_Test.py:3000 clicked on Register Learner Button INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/login INFO  setup:test_LMS_Regression_Test.py:3006 Logging in Learner INFO  setup:test_LMS_Regression_Test.py:3009 learner Login Success INFO  setup:test_LMS_Regression_Test.py:3017 Total Courses Purchased : 2 INFO  setup:test_LMS_Regression_Test.py:3019 course purchased is : Agile Scrum Foundation INFO  setup:test_LMS_Regression_Test.py:3019 course purchased is : Agile Scrum Master(ASM®) INFO  setup:test_LMS_Regression_Test.py:3022 Logging out Learner
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_B2C_NewUser_MultiPurchase_CPL 635.61
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68A23A30>, initialize_pages = None
testdata = {'asm': '/agile-and-scrum', 'card_name': 'simplilearn', 'credit_number': '4111 1111 1111 1111', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T16688","high","LMS Regression","pradeep")
def test_B2C_NewUser_MultiPurchase_CPL(self,initialize_pages,testdata):

'''
Objective: To check the purchase flow for a new user purchasing a multiple product from RevX via CPL creation.

Step 01: Purchase a multiple product for a new user via RevX.
Step 02: Vertify end to end order purchase flow.
'''

email_id = utils.generate_random_email_regression_()
name = testdata['name']
last_name = "testlastname"
logging.info(f"email id id : {email_id}")
#dump data for future use
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
data['testdata_for_lms_regression']['learner_CPL_multiple_course']=email_id

with open("LMS_regression_testdata.json",'w') as file:
json.dump(data,file,indent=4)

logging.info("test data Loaded")
pytest.driver.delete_all_cookies()

salesforce_login_helper.sf_login()
# Creating the order/Generating the order for regular
revx_helper.create_payment_multiple_course(testdata['payment_details'],email_id)

# Verifying the Payment Generate Link Message
revx_helper.verify_custom_link_message(email_id)

#logout from revx
logging.info("logging out From REVX")
self.pg_revx.logout.click()
time.sleep(10)
logging.info("logout from RevX success")

#Get payment link From mail box
pytest.driver.delete_all_cookies()
pytest.driver.get(pytest.config['yopmail_url'])
logging.info("yopmail URL Opened")
time.sleep(5)
self.pg_assignment.yopmail_mail_login(email_id)
logging.info("logged in to Yopmail")
pytest.driver.switch_to.frame(self.pg_assignment.yopmail_iframe_message)

default_handle = pytest.driver.current_window_handle
if selenium_helper.is_element_present(self.pg_assignment.locators['payment_link'][0],5) == True:
self.pg_assignment.payment_link.click()
logging.info("CLicked on Payment link in Yopmail")
time.sleep(5)
handles = list(pytest.driver.window_handles)
for handle_check_counter in range(1,10):
if len(handles) >1:
pytest.driver.close()
pytest.driver.switch_to.window(handles[1])
break

#Make Payment
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
time.sleep(10)
logging.info("paymenr page opened")
self.pg_lms.generate_payment(name,email_id)
logging.info("payment done Successfully")

time.sleep(10)
self.pg_revx.btn_go_to_myCourses.click()
logging.info("clicked on Register Learner Button")
time.sleep(30)

#Register Learner
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
logging.info("registering Learner")
self.pg_signup.txt_lastname.set_text(last_name)
self.pg_signup.txt_password.set_text(testdata['password'])
self.pg_signup.verify_checkbox_selected()
self.pg_signup.btn_signup.click_button()
logging.info("learner Registration Success")

lms_login_helper.new_b2c_login(email_id,testdata['password'])
time.sleep(30)
# Incase user redirected to oob form page , then need to fill the form and then continue
if testdata['onboarding_url'] in pytest.driver.current_url:
logging.info("landed on Obb Form")
self.pg_onboarding.onboardfill_for_CPL(email_id)
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
time.sleep(20)
logging.info("learner landed on Dashboard")

for iterator in range(0,3):
if selenium_helper.is_element_present(self.pg_assignment.locators['button_got_it'][0],20) == True:
> self.pg_assignment.button_got_it.click()

test\test_LMS_Regression_Test.py:3122:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <button _ngcontent-osj-c40="" class="joyride-button" ng-reflect-ng-style="[object Object]" style="background-color: rgb(59, 85, 96); color: rgb(255, 255, 255); border-color: transparent;">...</button> is not clickable at point (731, 669). Other element would receive the click: <path fill="rgb(82,170,243)" fill-opacity="1" d=" M480.97149658203125,-326.70050048828125 C480.97149658203125,-326.70050048828125 480.97149658203125,326.70050048828125 480.97149658203125,326.70050048828125 C480.97149658203125,326.70050048828125 -480.97149658203125,326.70050048828125 -480.97149658203125,326.70050048828125 C-480.97149658203125,326.70050048828125 -480.97149658203125,-326.70050048828125 -480.97149658203125,-326.70050048828125 C-480.97149658203125,-326.70050048828125 480.97149658203125,-326.70050048828125 480.97149658203125,-326.70050048828125z"></path>
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:3043 email id id : iris_regression1089@yopmail.com INFO  setup:test_LMS_Regression_Test.py:3052 test data Loaded WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8087/apachedev/git/ice9/backend/public/sso/payment is not present INFO  setup:revx_helper.py:245 changing docker to 8085 INFO  setup:revx_helper.py:305 Adding Product INFO  setup:revx_helper.py:329 clicked on Add Button INFO  setup:revx_helper.py:305 Adding Product INFO  setup:revx_helper.py:467 payment link generated is : Following link has been sent to your customer: Payment link: http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=18086e2c067fea4e140c65c974de6f0aaeab6b5e07452170076b9247f60e03f2 INFO  setup:test_LMS_Regression_Test.py:3063 logging out From REVX INFO  setup:test_LMS_Regression_Test.py:3066 logout from RevX success INFO  setup:test_LMS_Regression_Test.py:3071 yopmail URL Opened INFO  setup:assignment_page.py:138 The email used for yopmail login is : iris_regression1089@yopmail.com INFO  setup:test_LMS_Regression_Test.py:3074 logged in to Yopmail INFO  setup:test_LMS_Regression_Test.py:3080 CLicked on Payment link in Yopmail INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=18086e2c067fea4e140c65c974de6f0aaeab6b5e07452170076b9247f60e03f2 INFO  setup:test_LMS_Regression_Test.py:3092 paymenr page opened WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8085/apachedev/git/ice9/frontend/public/cart/completed?authtoken=18086e2c067fea4e140c65c974de6f0aaeab6b5e07452170076b9247f60e03f2&authorization=success is not present INFO  setup:lms_page.py:600 order_number_idCSTM_6R5PTP49AV6 INFO  setup:test_LMS_Regression_Test.py:3094 payment done Successfully INFO  setup:test_LMS_Regression_Test.py:3098 clicked on Register Learner Button INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression1089@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage INFO  setup:test_LMS_Regression_Test.py:3103 registering Learner WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression1089@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression1089@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression1089@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not visible WARNING  setup:page_factory.py:57 the locator btn_signup on url http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/account-setup?setupAccount=true&userEmail=iris_regression1089@yopmail.com&userName=irisregressiontest&countryId=IN&phoneNo=%2091-9090909090&redirect_url=http://dockerv2.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard/oob/onboarding&referer=WebsiteThankYouPage is not present INFO  setup:test_LMS_Regression_Test.py:3108 learner Registration Success INFO  setup:test_LMS_Regression_Test.py:3118 learner landed on Dashboard
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_B2C_ReturningUser_MultiPurchase_CPL 467.80
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68EC6760>, initialize_pages = None
testdata = {'asm': '/agile-and-scrum', 'card_name': 'simplilearn', 'credit_number': '4111 1111 1111 1111', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T16689","high","LMS Regression","pradeep")
def test_B2C_ReturningUser_MultiPurchase_CPL(self,initialize_pages,testdata):

'''
Objective: To check the purchase flow for a Existing purchasing a multiple product from RevX via CPL creation.

Step 01: Purchase a multiple product for a new existing via RevX.
Step 02: Vertify end to end order purchase flow.
'''

with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['learner_CPL_multiple_course']
name = testdata['name']

logging.info("test data Loaded")
pytest.driver.delete_all_cookies()

salesforce_login_helper.sf_login()
# Creating the order/Generating the order for regular
revx_helper.create_payment_multiple_course_second_time(testdata['payment_details'],email_id)

# Verifying the Payment Generate Link Message
revx_helper.verify_custom_link_message(email_id)

#logout from revx
logging.info("logging out From REVX")
self.pg_revx.logout.click()
time.sleep(10)
logging.info("logout from RevX success")

#Get payment link From mail box
pytest.driver.delete_all_cookies()
pytest.driver.get(pytest.config['yopmail_url'])
logging.info("yopmail URL Opened")
time.sleep(5)
self.pg_assignment.yopmail_mail_login(email_id)
logging.info("logged in to Yopmail")
pytest.driver.switch_to.frame(self.pg_assignment.yopmail_iframe_message)

default_handle = pytest.driver.current_window_handle
if selenium_helper.is_element_present(self.pg_assignment.locators['payment_link'][0],5) == True:
self.pg_assignment.payment_link.click()
logging.info("CLicked on Payment link in Yopmail")
time.sleep(5)
handles = list(pytest.driver.window_handles)
for handle_check_counter in range(1,10):
if len(handles) >1:
pytest.driver.close()
pytest.driver.switch_to.window(handles[1])
break

#Make Payment
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
time.sleep(10)
logging.info("paymenr page opened")
self.pg_lms.generate_payment(name,email_id)
logging.info("payment done Successfully")

time.sleep(10)
self.pg_revx.btn_go_to_myCourses.click()
logging.info("clicked on Register Learner Button")
time.sleep(30)

#loging Learner
self.pg_lms.change_docker(pytest.config['revx_docker'],pytest.config['new_url'])
logging.info("Logging in Learner")
lms_login_helper.new_b2c_login(email_id,testdata['password'])
logging.info("learner logged in Success")
time.sleep(30)
if testdata['onboarding_url'] in pytest.driver.current_url:
logging.info("landed on Obb Form")
self.pg_onboarding.onboardfill_for_CPL(email_id)
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
if selenium_helper.is_element_present(self.pg_lms.locators["lms_walkthrough_popup"][0],5):
time.sleep(2)
self.pg_lms.lms_walkthrough_popup.click_button()
#lms_login_helper.new_b2c_login(email_id,testdata['password'])
selenium_helper.is_element_present(self.pg_lms.locators['agile_scrum_master'][0],120)
time.sleep(5)
all_courses = self.pg_lms.agile_scrum_master.get_all_elements()
logging.info(f"Total Courses Purchased : {len(all_courses)}")
for course in all_courses:
logging.info(f"course purchased is : {course.text}")

#logout as learner
logging.info("Logging out Learner")
time.sleep(2)
> self.pg_assignment.btn_logout_dropdown.click_button()

test\test_LMS_Regression_Test.py:3232:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
core\page_factory.py:195: in click_button
self.click()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:80: in click
self._execute(Command.CLICK_ELEMENT)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webelement.py:633: in _execute
return self._parent.execute(command, params)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 400, 'value': '{"value":{"error":"element click intercepted","message":"element click intercepted: Element ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <span _ngcontent-gul-c3="" class="profile-img">...</span> is not clickable at point (1486, 40). Other element would receive the click: <div class="joyride-backdrop backdrop-right" style="width: 100%; background-color: rgba(59, 85, 96, 0.7);"></div>
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: ElementClickInterceptedException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:3159 test data Loaded WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8087/apachedev/git/ice9/backend/public/sso/payment is not present INFO  setup:revx_helper.py:355 changing docker to 8085 INFO  setup:revx_helper.py:415 Adding Product INFO  setup:revx_helper.py:439 clicked on Add Button INFO  setup:revx_helper.py:415 Adding Product INFO  setup:revx_helper.py:467 payment link generated is : Following link has been sent to your customer: Payment link: http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=53831f70cdec0d54f13a3c1ac7c5d3cbec2c7b93634c52e5a9b0f508a8a53ff6 INFO  setup:test_LMS_Regression_Test.py:3170 logging out From REVX INFO  setup:test_LMS_Regression_Test.py:3173 logout from RevX success INFO  setup:test_LMS_Regression_Test.py:3178 yopmail URL Opened INFO  setup:assignment_page.py:138 The email used for yopmail login is : iris_regression1089@yopmail.com INFO  setup:test_LMS_Regression_Test.py:3181 logged in to Yopmail INFO  setup:test_LMS_Regression_Test.py:3187 CLicked on Payment link in Yopmail INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8085/apachedev/pigen/web_services/ssvc/public/checkout/details?authtoken=53831f70cdec0d54f13a3c1ac7c5d3cbec2c7b93634c52e5a9b0f508a8a53ff6 INFO  setup:test_LMS_Regression_Test.py:3199 paymenr page opened WARNING  setup:page_factory.py:57 the locator send_anyway on url http://dockerv2.simplilearn.com:8085/apachedev/git/ice9/frontend/public/cart/completed?authtoken=53831f70cdec0d54f13a3c1ac7c5d3cbec2c7b93634c52e5a9b0f508a8a53ff6&authorization=success is not present INFO  setup:lms_page.py:600 order_number_idCSTM_JP7FJO1D0YU INFO  setup:test_LMS_Regression_Test.py:3201 payment done Successfully INFO  setup:test_LMS_Regression_Test.py:3205 clicked on Register Learner Button INFO  setup:lms_page.py:606 Payment link after Docker Change : http://dockerv2.simplilearn.com:8561/apachedev/git/cloud6/public/user/login INFO  setup:test_LMS_Regression_Test.py:3210 Logging in Learner INFO  setup:test_LMS_Regression_Test.py:3212 learner logged in Success INFO  setup:test_LMS_Regression_Test.py:3225 Total Courses Purchased : 6 INFO  setup:test_LMS_Regression_Test.py:3227 course purchased is : Agile Certified Practitioner (PMI-ACP)® INFO  setup:test_LMS_Regression_Test.py:3227 course purchased is : Agile Scrum Foundation INFO  setup:test_LMS_Regression_Test.py:3227 course purchased is : Agile Scrum Master(ASM®) INFO  setup:test_LMS_Regression_Test.py:3227 course purchased is : Big Data Hadoop and Spark Developer INFO  setup:test_LMS_Regression_Test.py:3227 course purchased is : Core Java INFO  setup:test_LMS_Regression_Test.py:3227 course purchased is : Linux Training INFO  setup:test_LMS_Regression_Test.py:3230 Logging out Learner
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2CLearner_removeLearner 152.57
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68B4FD30>, initialize_pages = None
testdata = {'admin_url': '/admin', 'bundle_id': '163', 'bundle_name': 'Data Scientist', 'course_id': '163', ...}

@pytest.mark.test_details("SLUB-T18079","high","LMS Regression","Pradeep")
def test_Verify_B2CLearner_removeLearner(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the learner should be removed with the cohort and initial program expiry days should be resetted to the learner

Step 01: Execute the TC
Step 02: Perform Remove LEarner
Step 03: Verify the data on lms
Step 04: Verify the Cohort change request table
Step 05: Verify the Access days from the program card

'''
#Step 01: Execute the TC
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
cohort_name=data['testdata_for_lms_regression']['b2b_master_cohort1']

pytest.driver.delete_all_cookies()
email_id = TestLMSRegression.create_newUser(self,testdata)
logging.info("Neaw Learner Created Successfully")
logging.info(f"The leaner registered is : {email_id}")
time.sleep(10)

#Loginto the lms as admin
lms_login_helper.new_b2c_login(testdata['email'],testdata['password'])

# Wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])
# Go to admin URL
self.pg_certificate.goToSupportAssign(testdata['admin_url'])

#Click on Support-> Assignment
self.pg_assignment.click_onAssignment()
> self.pg_assignment.assign_MP_program_with_selected_cohort(testdata['bundle_id'],cohort_name,email_id)

test\test_LMS_Regression_Test.py:3596:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:32: in assign_MP_program_with_selected_cohort
self.select_cohort.select_element_by_text(cohort)
core\page_factory.py:127: in select_element_by_text
select.select_by_visible_text(text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.support.select.Select object at 0x000001EF688D06D0>
text = 'MS Full Stack Java Developer May 2022 cohort 303test data for LMS Regression'

def select_by_visible_text(self, text):
"""Select all options that display text matching the argument. That is, when given "Bar" this
would select an option like:

<option value="foo">Bar</option>

:Args:
- text - The visible text to match against

throws NoSuchElementException If there is no option with specisied text in SELECT
"""
xpath = ".//option[normalize-space(.) = %s]" % self._escapeString(text)
opts = self._el.find_elements(By.XPATH, xpath)
matched = False
for opt in opts:
self._setSelected(opt)
if not self.is_multiple:
return
matched = True

if len(opts) == 0 and " " in text:
subStringWithoutSpace = self._get_longest_token(text)
if subStringWithoutSpace == "":
candidates = self.options
else:
xpath = ".//option[contains(.,%s)]" % self._escapeString(subStringWithoutSpace)
candidates = self._el.find_elements(By.XPATH, xpath)
for candidate in candidates:
if text == candidate.text:
self._setSelected(candidate)
if not self.is_multiple:
return
matched = True

if not matched:
> raise NoSuchElementException("Could not locate element with visible text: %s" % text)
E selenium.common.exceptions.NoSuchElementException: Message: Could not locate element with visible text: MS Full Stack Java Developer May 2022 cohort 303test data for LMS Regression

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\support\select.py:140: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:3582 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:3583 The leaner registered is : irisregression227@yopmail.com INFO  setup:assignment_page.py:211 clicked on Assignment
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2CLearner_AddLearner 0.00
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69661550>, initialize_pages = None
testdata = {'bundle_id': '163', 'cohort_mp': 'mp', 'course_mp': 'Full Stack Java Developer - 163', 'course_pgp': 'Post Graduate Program in Data Science - 156', ...}

@pytest.mark.test_details("SLUB-T18080","high","LMS Regression","Pradeep")
def test_Verify_B2CLearner_AddLearner(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the learner should be added with the cohort and initial program expiry days should be resetted to the cohort expiry if it is greater than program expiry

Step 01: Execute the TC
Step 02: Create cohort & announce classes
Step 03: Perform ADDLEarner
Step 04: Verify the data on lms
Step 05: Verify the Cohort change request table
Step 06: Verify the Access days from the program card

'''
#Step 01: Execute the TC
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
cohort_name=data['testdata_for_lms_regression']['b2b_master_cohort2']

> email_id = email_id_for_next_use[0]
E IndexError: list index out of range

test\test_LMS_Regression_Test.py:3731: IndexError
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BLMS_ScormLearnerAccesstoCourse 16.16
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF694CC790>, initialize_pages = None
testdata = {'b2b_admin_dashboard': '/public/affiliate', 'email': 'admin@simplilearn.com', 'enterprise_id': '1323', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T18069","high","LMS Regression","Pradeep")
def test_Verify_B2BLMS_ScormLearnerAccesstoCourse(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the program successfully


Step 01: Create cohort & announce classes
Step 02: Assign the program
Step 03: verify the cohort is assigned successfully

'''
email_id = utils.generate_random_email_regression_b2b()
logging.info(email_id)

> lms_login_helper.b2b_admin_login(pytest.config['admin']['email'],pytest.config['admin']['password'])

test\test_LMS_Regression_Test.py:3825:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:260: in b2b_admin_login
pg_login.b2blogin(email,password)
pages\login_page.py:53: in b2blogin
self.txt_email.set_text(email)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.login_page.LoginPage object at 0x000001EF69491760>, loc = 'txt_email'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: txt_email

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:3823 irisregressiontestb2b+vsz@yopmail.com WARNING  setup:page_factory.py:57 the locator txt_email on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present WARNING  setup:page_factory.py:57 the locator txt_email on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present WARNING  setup:page_factory.py:57 the locator txt_email on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BLMS_XAPI 15.94
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF68B4F7C0>, initialize_pages = None
testdata = {'b2b_admin_dashboard': '/public/affiliate', 'email': 'admin@simplilearn.com', 'enterprise_id': '1323', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T18070","high","LMS Regression","Pradeep")
def test_Verify_B2BLMS_XAPI(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the xapi access should be done successfully


Step 01: Create cohort & announce classes
Step 02: Assign the program
Step 03: verify the cohort is assigned successfully

'''
email_id = utils.generate_random_email_regression_b2b()
logging.info(email_id)

> lms_login_helper.b2b_admin_login(pytest.config['admin']['email'],pytest.config['admin']['password'])

test\test_LMS_Regression_Test.py:3879:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:260: in b2b_admin_login
pg_login.b2blogin(email,password)
pages\login_page.py:53: in b2blogin
self.txt_email.set_text(email)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.login_page.LoginPage object at 0x000001EF694366A0>, loc = 'txt_email'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: txt_email

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:3877 irisregressiontestb2b+kei@yopmail.com WARNING  setup:page_factory.py:57 the locator txt_email on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present WARNING  setup:page_factory.py:57 the locator txt_email on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present WARNING  setup:page_factory.py:57 the locator txt_email on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_EntAdmin_CohortProgram_NewUser 251.60
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69436670>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Full Stack Java Developer-163', 'cohort_mp': 'mp', ...}

@pytest.mark.test_details("SLUB-T18071","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_EntAdmin_CohortProgram_NewUser(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the program successfully


Step 01: Create cohort & announce classes
Step 02: Assign the program
Step 03: verify the cohort is assigned successfully

'''

#step 01 : Create cohort & announce classes
#create Cohort

lms_login_helper.engagex_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
self.pg_cohort.click_new_cohort()
selenium_helper.is_element_present(self.pg_cohort.locators['cohort_creation_window'][0],60)
self.pg_cohort.create_cohort_class_stage_1(testdata['cohort_mp'])
self.pg_cohort.create_cohort_class_stage_2(testdata['manager_name'],testdata['link'],testdata['course_mp'])
cohort_name=self.pg_cohort.create_cohort_class_stage_3and4(testdata['text'],testdata['link'])
cohort_program.append(cohort_name)

#announce classes
self.pg_cohort.select_to_particular_cohort(cohort_name)
first_class_cohort1 = self.pg_cohort.create_class_existing_firstcohort_firstclass(testdata['instructor'],cohort_name,testdata['teaching_assistance'])
time.sleep(10)
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
data['testdata_for_lms_regression']['b2b_master_cohort1']=cohort_name

with open("LMS_regression_testdata.json",'w') as file:
json.dump(data,file,indent=4)

time.sleep(2)
lms_login_helper.engagex_logout()
time.sleep(10)
logging.info(f"{cohort_program[0]} , {len(cohort_program)}")

#Step 02: Assign the program
#cohort_name="MS Full Stack Java Developer May 2022 cohort 279test data for LMS Regression"
name= utils.generate_random_name_regression_b2b()
email_id=utils.generate_random_email_regression_b2b()

lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
#time.sleep(5)
logging.info("logged in to xenia successfull..!!")
selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:3982:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF6895DEB0>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 mp INFO  setup:cohorts_page.py:47 MP Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:70 course name set to Full Stack Java Developer - 163 INFO  setup:cohorts_page.py:74 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression'] INFO  setup:cohorts_page.py:170 MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression cohort is present INFO  setup:cohorts_page.py:172 cohort name match INFO  setup:cohorts_page.py:180 clicked on classes tab INFO  setup:cohorts_page.py:184 clicked on New-live-classes button INFO  setup:cohorts_page.py:193 stage 4 started ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3264/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3264/classes/ongoing is not present INFO  setup:cohorts_page.py:218 clicked on next button INFO  setup:cohorts_page.py:219 stage 5 started INFO  setup:cohorts_page.py:224 Test data for automation - added to class name INFO  setup:cohorts_page.py:227 clicked on next button after adding text INFO  setup:cohorts_page.py:233 class created with class name # Machine Learning JUNE 2022 batch 4Test data for CCR automation # INFO  setup:cohorts_page.py:234 stage 6 started INFO  setup:test_LMS_Regression_Test.py:3967 MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression , 1 WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:3977 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_EntAdmin_UniversityProgram_NewUser 251.93
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69436D30>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Post Graduate Program in Data Science-156', 'cohort_mp': 'mp', ...}

@pytest.mark.test_details("SLUB-T18072","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_EntAdmin_UniversityProgram_NewUser(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the program successfully

Step 01: Create cohort & announce classes
Step 02: Assign the program
Step 03: verify the cohort is assigned successfully

'''
#step 01 : Create cohort & announce classes
#create Cohort

lms_login_helper.engagex_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
self.pg_cohort.click_new_cohort()
selenium_helper.is_element_present(self.pg_cohort.locators['cohort_creation_window'][0],60)
self.pg_cohort.create_cohort_class_stage_1(testdata['cohort_university'])
self.pg_cohort.create_cohort_class_stage_2(testdata['manager_name'],testdata['link'],testdata['course_pgp'])
cohort_name=self.pg_cohort.create_cohort_class_stage_3and4(testdata['text'],testdata['link'])
cohort_program.append(cohort_name)

#announce classes
self.pg_cohort.select_to_particular_cohort(cohort_name)
first_class_cohort1 = self.pg_cohort.create_class_existing_firstcohort_firstclass(testdata['instructor'],cohort_name,testdata['teaching_assistance'])
time.sleep(10)
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
data['testdata_for_lms_regression']['b2b_university_cohort1']=cohort_name

with open("LMS_regression_testdata.json",'w') as file:
json.dump(data,file,indent=4)

time.sleep(2)
lms_login_helper.engagex_logout()
time.sleep(10)
logging.info(f"{cohort_program[0]} , {len(cohort_program)}")

#Step 02: Assign the program
#cohort_name ="PGP Data Science May 2022 cohort 415test data for LMS Regression"

name= utils.generate_random_name_regression_b2b()
email_id=utils.generate_random_email_regression_b2b()

lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
#time.sleep(5)
logging.info("logged in to xenia successfull..!!")
selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4103:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF6895D100>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 pgp INFO  setup:cohorts_page.py:53 UNIVERSITY Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:70 course name set to Post Graduate Program in Data Science - 156 INFO  setup:cohorts_page.py:74 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 466test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 466test data for LMS Regression'] INFO  setup:cohorts_page.py:170 PGP Data Science Jun 2022 cohort 466test data for LMS Regression cohort is present INFO  setup:cohorts_page.py:172 cohort name match INFO  setup:cohorts_page.py:180 clicked on classes tab INFO  setup:cohorts_page.py:184 clicked on New-live-classes button INFO  setup:cohorts_page.py:193 stage 4 started ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3265/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3265/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3265/classes/ongoing is not present INFO  setup:cohorts_page.py:218 clicked on next button INFO  setup:cohorts_page.py:219 stage 5 started INFO  setup:cohorts_page.py:224 Test data for automation - added to class name INFO  setup:cohorts_page.py:227 clicked on next button after adding text INFO  setup:cohorts_page.py:233 class created with class name # .NET FSD Casptone Project JUNE 2022 batch 3Test data for CCR automation # INFO  setup:cohorts_page.py:234 stage 6 started INFO  setup:test_LMS_Regression_Test.py:4087 MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression , 2 WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4098 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_EntAdmin_ClassicProgram_NewUser 68.14
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF6895D430>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Learning Structure bundle-1-294', 'confirm_password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T18073","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_EntAdmin_ClassicProgram_NewUser(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the program successfully

Step 01: Assign the program

'''
name= utils.generate_random_name_regression_b2b()
email_id=utils.generate_random_email_regression_b2b()

lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")

selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4179:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF6943A070>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4173 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_verify_B2BAssignment_EntAdmin_CertificationCourse 68.36
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69982F10>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Core Java Certification Training', 'confirm_password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T18074","high","LMS Regression","Pradeep")
def test_verify_B2BAssignment_EntAdmin_CertificationCourse(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the course successfully


Step 01: Assign the program

'''

name= utils.generate_random_name_regression_b2b()
email_id=utils.generate_random_email_regression_b2b()

lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")

selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4255:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF698196D0>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4249 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_EntAdmin_CohortProgram_ExistingUser 258.30
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF697D00A0>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Full Stack Java Developer-163', 'cohort_mp': 'mp', ...}

@pytest.mark.test_details("SLUB-T18075","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_EntAdmin_CohortProgram_ExistingUser(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the existinglearner should be assigned the program successfully


Step 01: Create cohort & announce classes
Step 02: Assign the program
Step 03: verify the cohort is assigned successfully

'''
#step 01 : Create cohort & announce classes
#create Cohort

lms_login_helper.engagex_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
selenium_helper.is_element_present(self.pg_cohort.locators['upcomming_cohort_1stPage'][0],60)
time.sleep(2)

self.pg_cohort.click_new_cohort()
selenium_helper.is_element_present(self.pg_cohort.locators['cohort_creation_window'][0],60)
self.pg_cohort.create_cohort_class_stage_1(testdata['cohort_mp'])
self.pg_cohort.create_cohort_class_stage_2(testdata['manager_name'],testdata['link'],testdata['course_mp'])
cohort_name=self.pg_cohort.create_cohort_class_stage_3and4(testdata['text'],testdata['link'])
cohort_program.append(cohort_name)

#announce classes
self.pg_cohort.select_to_particular_cohort(cohort_name)
first_class_cohort2 = self.pg_cohort.create_class_existing_firstcohort_firstclass(testdata['instructor'],cohort_name,testdata['teaching_assistance'])
time.sleep(10)
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
data['testdata_for_lms_regression']['b2b_master_cohort2']=cohort_name

with open("LMS_regression_testdata.json",'w') as file:
json.dump(data,file,indent=4)

time.sleep(2)
lms_login_helper.engagex_logout()
time.sleep(10)

#Step 02: Assign the program
#cohort_name="MS Full Stack Java Developer May 2022 cohort 256test data for LMS Regression"
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['b2b_university_learner1']

lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")
selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4366:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF69396280>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 mp INFO  setup:cohorts_page.py:47 MP Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:70 course name set to Full Stack Java Developer - 163 INFO  setup:cohorts_page.py:74 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 466test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 344test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 466test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 344test data for LMS Regression'] INFO  setup:cohorts_page.py:170 MS Full Stack Java Developer Jun 2022 cohort 344test data for LMS Regression cohort is present INFO  setup:cohorts_page.py:172 cohort name match INFO  setup:cohorts_page.py:180 clicked on classes tab INFO  setup:cohorts_page.py:184 clicked on New-live-classes button INFO  setup:cohorts_page.py:193 stage 4 started ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3266/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3266/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3266/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3266/classes/ongoing is not present INFO  setup:cohorts_page.py:218 clicked on next button INFO  setup:cohorts_page.py:219 stage 5 started INFO  setup:cohorts_page.py:224 Test data for automation - added to class name INFO  setup:cohorts_page.py:227 clicked on next button after adding text INFO  setup:cohorts_page.py:233 class created with class name # Machine Learning JUNE 2022 batch 5Test data for CCR automation # INFO  setup:cohorts_page.py:234 stage 6 started WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4361 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_EntAdmin_UniversityProgram_ExistingUser 122.42
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69396940>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Post Graduate Program in Data Science-156', 'cohort_mp': 'pgp', ...}

@pytest.mark.test_details("SLUB-T18076","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_EntAdmin_UniversityProgram_ExistingUser(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the existinglearner should be assigned the program successfully


Step 01: Create cohort & announce classes
Step 02: Assign the program
Step 03: verify the cohort is assigned successfully

'''
#step 01 : Create cohort & announce classes
#create Cohort

lms_login_helper.engagex_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
selenium_helper.is_element_present(self.pg_cohort.locators['upcomming_cohort_1stPage'][0],60)
time.sleep(2)

self.pg_cohort.click_new_cohort()
selenium_helper.is_element_present(self.pg_cohort.locators['cohort_creation_window'][0],60)
self.pg_cohort.create_cohort_class_stage_1(testdata['cohort_mp'])
self.pg_cohort.create_cohort_class_stage_2(testdata['manager_name'],testdata['link'],testdata['course_mp'])
cohort_name=self.pg_cohort.create_cohort_class_stage_3and4(testdata['text'],testdata['link'])
cohort_program.append(cohort_name)

#announce classes
> self.pg_cohort.select_to_particular_cohort(cohort_name)

test\test_LMS_Regression_Test.py:4444:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\cohorts_page.py:498: in select_to_particular_cohort
self.cohort_card.click_button()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.cohorts_page.CohortsPage object at 0x000001EF69396DF0>, loc = 'cohort_card'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: cohort_card

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 pgp INFO  setup:cohorts_page.py:53 UNIVERSITY Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:70 course name set to Post Graduate Program in Data Science - 156 INFO  setup:cohorts_page.py:74 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 466test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 344test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 467test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 343test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 466test data for LMS Regression', 'MS Full Stack Java Developer Jun 2022 cohort 344test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 467test data for LMS Regression'] ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//div[@class='cohorts-row']//div//div//a)[1]") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming is not present WARNING  setup:page_factory.py:57 the locator cohort_card on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BAssignment_EntAdmin_ClassicProgram_ExistingUser 68.54
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF697F8790>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Data Scientistsshhhzzz-67', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T18077","high","LMS Regression","Pradeep")
def test_Verify_B2BAssignment_EntAdmin_ClassicProgram_ExistingUser(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the program successfully

Step 01: Assign the program

'''
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['b2b_classic_learner1']

lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")

selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4533:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF697E9EB0>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4527 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_verify_B2BAssignment_EntAdmin_CertificationCourse_existinguser 64.41
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69C8DEB0>, initialize_pages = None
testdata = {'add_url': '/add', 'b2b_admin_dashboard': '/public/affiliate', 'b2b_mp_course': 'Big Data Hadoop and Spark Developer', 'dashboard_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T18078","high","LMS Regression","Pradeep")
def test_verify_B2BAssignment_EntAdmin_CertificationCourse_existinguser(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the new learner should be assigned the program successfully

Step 01: Assign the program

'''
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['b2b_certification_learner1']

pytest.driver.delete_all_cookies()
lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")

selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4593:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF69BCCD30>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4587 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_ELVCAssignment_AutoRegisterEnable 404.14
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF693CFF40>, initialize_pages = None
testdata = {'b2b_admin_dashboard': '/public/affiliate', 'course_name': 'Data Science with R Programming', 'dashboard_url': '/dashboard', 'email': 'admin@simplilearn.com', ...}

@pytest.mark.test_details("SLUB-T18083","high","LMS Regression","Pradeep")
def test_Verify_ELVCAssignment_AutoRegisterEnable(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the ELVC should be created and assigned to learner successfully

Step 01: verify_B2BAssignment_EntAdmin_CertificationCourse
Step 03: Create the ELVC and enable Auto Register
Step 03: Login to enterprise admin portal
Step 04: Select the course and click on exclusive live class
Step 05: Search the class created in Step2
Step 06: Assign the class
Step 07: Login to learner's lms and verify the class tab
'''

with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['b2b_certification_learner1']

lms_login_helper.engagex_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
elvc_class = self.pg_elvc.createElvcFlexiClass(testdata['course_name'])
time.sleep(2)
lms_login_helper.engagex_logout()
time.sleep(10)

pytest.driver.delete_all_cookies()
lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")
selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4667:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF685CC280>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:b2b_ELVC.py:244 Instructor preethi is selected INFO  setup:b2b_ELVC.py:135 Data Science with R Programming MAY 2022 batch 1 automation team WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4662 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_ELVCAssignment_AutoRegisterDisable 406.42
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69C3D2E0>, initialize_pages = None
testdata = {'b2b_admin_dashboard': '/public/affiliate', 'course_name': 'Machine Learning', 'dashboard_url': '/dashboard', 'email': 'admin@simplilearn.com', ...}

@pytest.mark.test_details("SLUB-T18084","high","LMS Regression","Pradeep")
def test_Verify_ELVCAssignment_AutoRegisterDisable(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the ELVC should be created and learner should be able to register successfully

Step 01: verify_B2BAssignment_EntAdmin_CertificationCourse
Step 02: Create the ELVC and enable Auto Register
Step 03: Login to enterprise admin portal
Step 04: Select the course and click on exclusive live class
Step 05: Search the class created in Step2
Step 06: Assign the class
Step 07: Login to learner's lms and verify the class tab
'''

with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
email_id=data['testdata_for_lms_regression']['b2b_certification_learner1']

lms_login_helper.engagex_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(120,testdata['dashboard_url'])
elvc_class = self.pg_elvc.createElvcFlexiClass_without_auroRegister(testdata['course_name'])
time.sleep(2)
lms_login_helper.engagex_logout()
time.sleep(10)

pytest.driver.delete_all_cookies()
lms_login_helper.xenia_new_login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(60,testdata['xenia_home_url'])
logging.info("logged in to xenia successfull..!!")
selenium_helper.is_element_present(self.pg_certificate.locators['btn_fin_sale'][0],60)
self.pg_assignment.b2b_view_all_enterprise()

selenium_helper.wait_for_page_to_load(10,testdata['sellers_url'])
> self.pg_assignment.b2b_login_as_manager(testdata['enterprise_id'])

test\test_LMS_Regression_Test.py:4728:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\assignment_page.py:62: in b2b_login_as_manager
assert (enterprose_id == self.label_id_field.text)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.assignment_page.AssignmentPage object at 0x000001EF685CCE50>, loc = 'label_id_field'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_id_field

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/classes/ongoing is not present INFO  setup:b2b_ELVC.py:244 Instructor preethi is selected INFO  setup:b2b_ELVC.py:135 Machine Learning MAY 2022 batch 5 automation team WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_email on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator edt_password on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present WARNING  setup:page_factory.py:57 the locator btn_login on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/index/login is not present INFO  setup:test_LMS_Regression_Test.py:4723 logged in to xenia successfull..!! WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present WARNING  setup:page_factory.py:57 the locator label_id_field on url http://dockerv5.simplilearn.com:8083/apachedev/git/xenia/public/finsale/affiliate/manage-resellers is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BLearner_removeLearner 11.84
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF693329D0>, initialize_pages = None
testdata = {'bundle_id': '163', 'dashboard_url': '/dashboard', 'db_type': 'mysql', 'email': 'admin@simplilearn.com', ...}

@pytest.mark.test_details("SLUB-T18081","high","LMS Regression","Pradeep")
def test_Verify_B2BLearner_removeLearner(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the learner should be removed with the cohort and initial program expiry days should be resetted to the learner

Step 01: Execute the TC
Step 02: Perform Remove LEarner
Step 03: Verify the data on lms
Step 04: Verify the Cohort change request table
Step 05: Verify the Access days from the program card

'''
#Step 01: Execute the TC
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
cohort_name=data['testdata_for_lms_regression']['b2b_master_cohort2']
email_id = data['testdata_for_lms_regression']['b2b_university_learner1']

#verify data before Cohort Removal
> lms_login_helper.b2b_learner_login_new(email_id,testdata['password'])

test\test_LMS_Regression_Test.py:4777:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:253: in b2b_learner_login_new
pg_login.b2b_learner_login(email,password)
pages\login_page.py:48: in b2b_learner_login
self.b2b_learner_email_textbox.send_keys(email)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.login_page.LoginPage object at 0x000001EF69C5D0D0>, loc = 'b2b_learner_email_textbox'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: b2b_learner_email_textbox

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator b2b_learner_email_textbox on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present WARNING  setup:page_factory.py:57 the locator b2b_learner_email_textbox on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_Verify_B2BLearner_AddLearner 11.72
self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF686D22E0>, initialize_pages = None
testdata = {'bundle_id': '163', 'dashboard_url': '/dashboard', 'db_type': 'mysql', 'email': 'admin@simplilearn.com', ...}

@pytest.mark.test_details("SLUB-T18082","high","LMS Regression","Pradeep")
def test_Verify_B2BLearner_AddLearner(self,initialize_pages,testdata):
'''
Objective : This test is to verify that the learner should be added with the cohort and initial program expiry days should be resetted to the cohort expiry if it is greater than program expiry

Step 01: Execute the TC
Step 02: Create cohort & announce classes
Step 03: Perform ADDLEarner
Step 04: Verify the data on lms
Step 05: Verify the Cohort change request table
Step 06: Verify the Access days from the program card
'''

#Step 01: Execute the TC
#Step 02: Create cohort & announce classes
with open("LMS_regression_testdata.json",'r') as file:
data=json.load(file)
cohort_name=data['testdata_for_lms_regression']['b2b_master_cohort1']
email_id = data['testdata_for_lms_regression']['b2b_university_learner1']

logging.info(f"Learner Email id : {email_id}")
#verify data before Cohort Removal
> lms_login_helper.b2b_learner_login_new(email_id,testdata['password'])

test\test_LMS_Regression_Test.py:4878:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:253: in b2b_learner_login_new
pg_login.b2b_learner_login(email,password)
pages\login_page.py:48: in b2b_learner_login
self.b2b_learner_email_textbox.send_keys(email)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.login_page.LoginPage object at 0x000001EF686D25E0>, loc = 'b2b_learner_email_textbox'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: b2b_learner_email_textbox

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:4876 Learner Email id : irisregressiontestb2b+yhy@yopmail.com WARNING  setup:page_factory.py:57 the locator b2b_learner_email_textbox on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present WARNING  setup:page_factory.py:57 the locator b2b_learner_email_textbox on url http://catelogapi.dockerv5.simplilearn.com:8083/apachedev/git/paperclip/public/affiliate/user/login is not present
Failed test_LMS_Regression_Test.py::TestLMSRegression::test_MigrationScript_VerifyClassRegisterationCount 42.18
self = <urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>

def _new_conn(self):
""" Establish a socket connection and set nodelay settings on it.

:return: New socket connection.
"""
extra_kw = {}
if self.source_address:
extra_kw["source_address"] = self.source_address

if self.socket_options:
extra_kw["socket_options"] = self.socket_options

try:
> conn = connection.create_connection(
(self._dns_host, self.port), self.timeout, **extra_kw
)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connection.py:159:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

address = ('workshop.simplilearn.com', 443), timeout = None, source_address = None, socket_options = [(6, 1, 1)]

def create_connection(
address,
timeout=socket._GLOBAL_DEFAULT_TIMEOUT,
source_address=None,
socket_options=None,
):
"""Connect to *address* and return the socket object.

Convenience function. Connect to *address* (a 2-tuple ``(host,
port)``) and return the socket object. Passing the optional
*timeout* parameter will set the timeout on the socket instance
before attempting to connect. If no *timeout* is supplied, the
global default timeout setting returned by :func:`getdefaulttimeout`
is used. If *source_address* is set it must be a tuple of (host, port)
for the socket to bind as a source address before making the connection.
An host of '' or port 0 tells the OS to use the default.
"""

host, port = address
if host.startswith("["):
host = host.strip("[]")
err = None

# Using the value from allowed_gai_family() in the context of getaddrinfo lets
# us select whether to work with IPv4 DNS records, IPv6 records, or both.
# The original create_connection function always returns all records.
family = allowed_gai_family()

for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):
af, socktype, proto, canonname, sa = res
sock = None
try:
sock = socket.socket(af, socktype, proto)

# If provided, set socket level options before connecting.
_set_socket_options(sock, socket_options)

if timeout is not socket._GLOBAL_DEFAULT_TIMEOUT:
sock.settimeout(timeout)
if source_address:
sock.bind(source_address)
sock.connect(sa)
return sock

except socket.error as e:
err = e
if sock is not None:
sock.close()
sock = None

if err is not None:
> raise err

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\util\connection.py:84:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

address = ('workshop.simplilearn.com', 443), timeout = None, source_address = None, socket_options = [(6, 1, 1)]

def create_connection(
address,
timeout=socket._GLOBAL_DEFAULT_TIMEOUT,
source_address=None,
socket_options=None,
):
"""Connect to *address* and return the socket object.

Convenience function. Connect to *address* (a 2-tuple ``(host,
port)``) and return the socket object. Passing the optional
*timeout* parameter will set the timeout on the socket instance
before attempting to connect. If no *timeout* is supplied, the
global default timeout setting returned by :func:`getdefaulttimeout`
is used. If *source_address* is set it must be a tuple of (host, port)
for the socket to bind as a source address before making the connection.
An host of '' or port 0 tells the OS to use the default.
"""

host, port = address
if host.startswith("["):
host = host.strip("[]")
err = None

# Using the value from allowed_gai_family() in the context of getaddrinfo lets
# us select whether to work with IPv4 DNS records, IPv6 records, or both.
# The original create_connection function always returns all records.
family = allowed_gai_family()

for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):
af, socktype, proto, canonname, sa = res
sock = None
try:
sock = socket.socket(af, socktype, proto)

# If provided, set socket level options before connecting.
_set_socket_options(sock, socket_options)

if timeout is not socket._GLOBAL_DEFAULT_TIMEOUT:
sock.settimeout(timeout)
if source_address:
sock.bind(source_address)
> sock.connect(sa)
E TimeoutError: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\util\connection.py:74: TimeoutError

During handling of the above exception, another exception occurred:

self = <urllib3.connectionpool.HTTPSConnectionPool object at 0x000001EF6A105580>, method = 'POST'
url = '/api/v2/workshops/list-by-filter', body = 'status=1'
headers = {'User-Agent': 'python-requests/2.24.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-aliv...8', 'Content-Type': 'application/x-www-form-urlencoded', 'Authorization': 'Basic bnVjbGV1czppYW1hbHZjbWljcm9zZXJ2aWNl'}
retries = Retry(total=0, connect=None, read=False, redirect=None, status=None), redirect = False
assert_same_host = False, timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None
release_conn = False, chunked = False, body_pos = None
response_kw = {'decode_content': False, 'preload_content': False}, conn = None, release_this_conn = True, err = None
clean_exit = False, timeout_obj = Timeout(connect=None, read=None, total=None), is_new_proxy_conn = False

def urlopen(
self,
method,
url,
body=None,
headers=None,
retries=None,
redirect=True,
assert_same_host=True,
timeout=_Default,
pool_timeout=None,
release_conn=None,
chunked=False,
body_pos=None,
**response_kw
):
"""
Get a connection from the pool and perform an HTTP request. This is the
lowest level call for making a request, so you'll need to specify all
the raw details.

.. note::

More commonly, it's appropriate to use a convenience method provided
by :class:`.RequestMethods`, such as :meth:`request`.

.. note::

`release_conn` will only behave as expected if
`preload_content=False` because we want to make
`preload_content=False` the default behaviour someday soon without
breaking backwards compatibility.

:param method:
HTTP request method (such as GET, POST, PUT, etc.)

:param body:
Data to send in the request body (useful for creating
POST requests, see HTTPConnectionPool.post_url for
more convenience).

:param headers:
Dictionary of custom headers to send, such as User-Agent,
If-None-Match, etc. If None, pool headers are used. If provided,
these headers completely replace any pool-specific headers.

:param retries:
Configure the number of retries to allow before raising a
:class:`~urllib3.exceptions.MaxRetryError` exception.

Pass ``None`` to retry until you receive a response. Pass a
:class:`~urllib3.util.retry.Retry` object for fine-grained control
over different types of retries.
Pass an integer number to retry connection errors that many times,
but no other types of errors. Pass zero to never retry.

If ``False``, then retries are disabled and any exception is raised
immediately. Also, instead of raising a MaxRetryError on redirects,
the redirect response will be returned.

:type retries: :class:`~urllib3.util.retry.Retry`, False, or an int.

:param redirect:
If True, automatically handle redirects (status codes 301, 302,
303, 307, 308). Each redirect counts as a retry. Disabling retries
will disable redirect, too.

:param assert_same_host:
If ``True``, will make sure that the host of the pool requests is
consistent else will raise HostChangedError. When False, you can
use the pool on an HTTP proxy and request foreign hosts.

:param timeout:
If specified, overrides the default timeout for this one
request. It may be a float (in seconds) or an instance of
:class:`urllib3.util.Timeout`.

:param pool_timeout:
If set and the pool is set to block=True, then this method will
block for ``pool_timeout`` seconds and raise EmptyPoolError if no
connection is available within the time period.

:param release_conn:
If False, then the urlopen call will not release the connection
back into the pool once a response is received (but will release if
you read the entire contents of the response such as when
`preload_content=True`). This is useful if you're not preloading
the response's content immediately. You will need to call
``r.release_conn()`` on the response ``r`` to return the connection
back into the pool. If None, it takes the value of
``response_kw.get('preload_content', True)``.

:param chunked:
If True, urllib3 will send the body using chunked transfer
encoding. Otherwise, urllib3 will send the body using the standard
content-length form. Defaults to False.

:param int body_pos:
Position to seek to in file-like body in the event of a retry or
redirect. Typically this won't need to be set because urllib3 will
auto-populate the value when needed.

:param \\**response_kw:
Additional parameters are passed to
:meth:`urllib3.response.HTTPResponse.from_httplib`
"""
if headers is None:
headers = self.headers

if not isinstance(retries, Retry):
retries = Retry.from_int(retries, redirect=redirect, default=self.retries)

if release_conn is None:
release_conn = response_kw.get("preload_content", True)

# Check host
if assert_same_host and not self.is_same_host(url):
raise HostChangedError(self, url, retries)

# Ensure that the URL we're connecting to is properly encoded
if url.startswith("/"):
url = six.ensure_str(_encode_target(url))
else:
url = six.ensure_str(parse_url(url).url)

conn = None

# Track whether `conn` needs to be released before
# returning/raising/recursing. Update this variable if necessary, and
# leave `release_conn` constant throughout the function. That way, if
# the function recurses, the original value of `release_conn` will be
# passed down into the recursive call, and its value will be respected.
#
# See issue #651 [1] for details.
#
# [1] <https://github.com/urllib3/urllib3/issues/651>
release_this_conn = release_conn

# Merge the proxy headers. Only do this in HTTP. We have to copy the
# headers dict so we can safely change it without those changes being
# reflected in anyone else's copy.
if self.scheme == "http":
headers = headers.copy()
headers.update(self.proxy_headers)

# Must keep the exception bound to a separate variable or else Python 3
# complains about UnboundLocalError.
err = None

# Keep track of whether we cleanly exited the except block. This
# ensures we do proper cleanup in finally.
clean_exit = False

# Rewind body position, if needed. Record current position
# for future rewinds in the event of a redirect/retry.
body_pos = set_file_position(body, body_pos)

try:
# Request a connection from the queue.
timeout_obj = self._get_timeout(timeout)
conn = self._get_conn(timeout=pool_timeout)

conn.timeout = timeout_obj.connect_timeout

is_new_proxy_conn = self.proxy is not None and not getattr(
conn, "sock", None
)
if is_new_proxy_conn:
self._prepare_proxy(conn)

# Make the request on the httplib connection object.
> httplib_response = self._make_request(
conn,
method,
url,
timeout=timeout_obj,
body=body,
headers=headers,
chunked=chunked,
)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connectionpool.py:670:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <urllib3.connectionpool.HTTPSConnectionPool object at 0x000001EF6A105580>
conn = <urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>, method = 'POST'
url = '/api/v2/workshops/list-by-filter', timeout = Timeout(connect=None, read=None, total=None), chunked = False
httplib_request_kw = {'body': 'status=1', 'headers': {'User-Agent': 'python-requests/2.24.0', 'Accept-Encoding': 'gzip, deflate', 'Accept':...', 'Content-Type': 'application/x-www-form-urlencoded', 'Authorization': 'Basic bnVjbGV1czppYW1hbHZjbWljcm9zZXJ2aWNl'}}
timeout_obj = Timeout(connect=None, read=None, total=None)

def _make_request(
self, conn, method, url, timeout=_Default, chunked=False, **httplib_request_kw
):
"""
Perform a request on a given urllib connection object taken from our
pool.

:param conn:
a connection from one of our connection pools

:param timeout:
Socket timeout in seconds for the request. This can be a
float or integer, which will set the same timeout value for
the socket connect and the socket read, or an instance of
:class:`urllib3.util.Timeout`, which gives you more fine-grained
control over your timeouts.
"""
self.num_requests += 1

timeout_obj = self._get_timeout(timeout)
timeout_obj.start_connect()
conn.timeout = timeout_obj.connect_timeout

# Trigger any extra validation we need to do.
try:
> self._validate_conn(conn)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connectionpool.py:381:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <urllib3.connectionpool.HTTPSConnectionPool object at 0x000001EF6A105580>
conn = <urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>

def _validate_conn(self, conn):
"""
Called right before a request is made, after the socket is created.
"""
super(HTTPSConnectionPool, self)._validate_conn(conn)

# Force connect early to allow us to validate the connection.
if not getattr(conn, "sock", None): # AppEngine might not have `.sock`
> conn.connect()

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connectionpool.py:978:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>

def connect(self):
# Add certificate verification
> conn = self._new_conn()

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connection.py:309:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>

def _new_conn(self):
""" Establish a socket connection and set nodelay settings on it.

:return: New socket connection.
"""
extra_kw = {}
if self.source_address:
extra_kw["source_address"] = self.source_address

if self.socket_options:
extra_kw["socket_options"] = self.socket_options

try:
conn = connection.create_connection(
(self._dns_host, self.port), self.timeout, **extra_kw
)

except SocketTimeout:
raise ConnectTimeoutError(
self,
"Connection to %s timed out. (connect timeout=%s)"
% (self.host, self.timeout),
)

except SocketError as e:
> raise NewConnectionError(
self, "Failed to establish a new connection: %s" % e
)
E urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connection.py:171: NewConnectionError

During handling of the above exception, another exception occurred:

self = <requests.adapters.HTTPAdapter object at 0x000001EF6A1053A0>, request = <PreparedRequest [POST]>, stream = False
timeout = Timeout(connect=None, read=None, total=None), verify = True, cert = None, proxies = OrderedDict()

def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None):
"""Sends PreparedRequest object. Returns Response object.

:param request: The :class:`PreparedRequest <PreparedRequest>` being sent.
:param stream: (optional) Whether to stream the request content.
:param timeout: (optional) How long to wait for the server to send
data before giving up, as a float, or a :ref:`(connect timeout,
read timeout) <timeouts>` tuple.
:type timeout: float or tuple or urllib3 Timeout object
:param verify: (optional) Either a boolean, in which case it controls whether
we verify the server's TLS certificate, or a string, in which case it
must be a path to a CA bundle to use
:param cert: (optional) Any user-provided SSL certificate to be trusted.
:param proxies: (optional) The proxies dictionary to apply to the request.
:rtype: requests.Response
"""

try:
conn = self.get_connection(request.url, proxies)
except LocationValueError as e:
raise InvalidURL(e, request=request)

self.cert_verify(conn, request.url, verify, cert)
url = self.request_url(request, proxies)
self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)

chunked = not (request.body is None or 'Content-Length' in request.headers)

if isinstance(timeout, tuple):
try:
connect, read = timeout
timeout = TimeoutSauce(connect=connect, read=read)
except ValueError as e:
# this may raise a string formatting error.
err = ("Invalid timeout {}. Pass a (connect, read) "
"timeout tuple, or a single float to set "
"both timeouts to the same value".format(timeout))
raise ValueError(err)
elif isinstance(timeout, TimeoutSauce):
pass
else:
timeout = TimeoutSauce(connect=timeout, read=timeout)

try:
if not chunked:
> resp = conn.urlopen(
method=request.method,
url=url,
body=request.body,
headers=request.headers,
redirect=False,
assert_same_host=False,
preload_content=False,
decode_content=False,
retries=self.max_retries,
timeout=timeout
)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\requests\adapters.py:439:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <urllib3.connectionpool.HTTPSConnectionPool object at 0x000001EF6A105580>, method = 'POST'
url = '/api/v2/workshops/list-by-filter', body = 'status=1'
headers = {'User-Agent': 'python-requests/2.24.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-aliv...8', 'Content-Type': 'application/x-www-form-urlencoded', 'Authorization': 'Basic bnVjbGV1czppYW1hbHZjbWljcm9zZXJ2aWNl'}
retries = Retry(total=0, connect=None, read=False, redirect=None, status=None), redirect = False
assert_same_host = False, timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None
release_conn = False, chunked = False, body_pos = None
response_kw = {'decode_content': False, 'preload_content': False}, conn = None, release_this_conn = True, err = None
clean_exit = False, timeout_obj = Timeout(connect=None, read=None, total=None), is_new_proxy_conn = False

def urlopen(
self,
method,
url,
body=None,
headers=None,
retries=None,
redirect=True,
assert_same_host=True,
timeout=_Default,
pool_timeout=None,
release_conn=None,
chunked=False,
body_pos=None,
**response_kw
):
"""
Get a connection from the pool and perform an HTTP request. This is the
lowest level call for making a request, so you'll need to specify all
the raw details.

.. note::

More commonly, it's appropriate to use a convenience method provided
by :class:`.RequestMethods`, such as :meth:`request`.

.. note::

`release_conn` will only behave as expected if
`preload_content=False` because we want to make
`preload_content=False` the default behaviour someday soon without
breaking backwards compatibility.

:param method:
HTTP request method (such as GET, POST, PUT, etc.)

:param body:
Data to send in the request body (useful for creating
POST requests, see HTTPConnectionPool.post_url for
more convenience).

:param headers:
Dictionary of custom headers to send, such as User-Agent,
If-None-Match, etc. If None, pool headers are used. If provided,
these headers completely replace any pool-specific headers.

:param retries:
Configure the number of retries to allow before raising a
:class:`~urllib3.exceptions.MaxRetryError` exception.

Pass ``None`` to retry until you receive a response. Pass a
:class:`~urllib3.util.retry.Retry` object for fine-grained control
over different types of retries.
Pass an integer number to retry connection errors that many times,
but no other types of errors. Pass zero to never retry.

If ``False``, then retries are disabled and any exception is raised
immediately. Also, instead of raising a MaxRetryError on redirects,
the redirect response will be returned.

:type retries: :class:`~urllib3.util.retry.Retry`, False, or an int.

:param redirect:
If True, automatically handle redirects (status codes 301, 302,
303, 307, 308). Each redirect counts as a retry. Disabling retries
will disable redirect, too.

:param assert_same_host:
If ``True``, will make sure that the host of the pool requests is
consistent else will raise HostChangedError. When False, you can
use the pool on an HTTP proxy and request foreign hosts.

:param timeout:
If specified, overrides the default timeout for this one
request. It may be a float (in seconds) or an instance of
:class:`urllib3.util.Timeout`.

:param pool_timeout:
If set and the pool is set to block=True, then this method will
block for ``pool_timeout`` seconds and raise EmptyPoolError if no
connection is available within the time period.

:param release_conn:
If False, then the urlopen call will not release the connection
back into the pool once a response is received (but will release if
you read the entire contents of the response such as when
`preload_content=True`). This is useful if you're not preloading
the response's content immediately. You will need to call
``r.release_conn()`` on the response ``r`` to return the connection
back into the pool. If None, it takes the value of
``response_kw.get('preload_content', True)``.

:param chunked:
If True, urllib3 will send the body using chunked transfer
encoding. Otherwise, urllib3 will send the body using the standard
content-length form. Defaults to False.

:param int body_pos:
Position to seek to in file-like body in the event of a retry or
redirect. Typically this won't need to be set because urllib3 will
auto-populate the value when needed.

:param \\**response_kw:
Additional parameters are passed to
:meth:`urllib3.response.HTTPResponse.from_httplib`
"""
if headers is None:
headers = self.headers

if not isinstance(retries, Retry):
retries = Retry.from_int(retries, redirect=redirect, default=self.retries)

if release_conn is None:
release_conn = response_kw.get("preload_content", True)

# Check host
if assert_same_host and not self.is_same_host(url):
raise HostChangedError(self, url, retries)

# Ensure that the URL we're connecting to is properly encoded
if url.startswith("/"):
url = six.ensure_str(_encode_target(url))
else:
url = six.ensure_str(parse_url(url).url)

conn = None

# Track whether `conn` needs to be released before
# returning/raising/recursing. Update this variable if necessary, and
# leave `release_conn` constant throughout the function. That way, if
# the function recurses, the original value of `release_conn` will be
# passed down into the recursive call, and its value will be respected.
#
# See issue #651 [1] for details.
#
# [1] <https://github.com/urllib3/urllib3/issues/651>
release_this_conn = release_conn

# Merge the proxy headers. Only do this in HTTP. We have to copy the
# headers dict so we can safely change it without those changes being
# reflected in anyone else's copy.
if self.scheme == "http":
headers = headers.copy()
headers.update(self.proxy_headers)

# Must keep the exception bound to a separate variable or else Python 3
# complains about UnboundLocalError.
err = None

# Keep track of whether we cleanly exited the except block. This
# ensures we do proper cleanup in finally.
clean_exit = False

# Rewind body position, if needed. Record current position
# for future rewinds in the event of a redirect/retry.
body_pos = set_file_position(body, body_pos)

try:
# Request a connection from the queue.
timeout_obj = self._get_timeout(timeout)
conn = self._get_conn(timeout=pool_timeout)

conn.timeout = timeout_obj.connect_timeout

is_new_proxy_conn = self.proxy is not None and not getattr(
conn, "sock", None
)
if is_new_proxy_conn:
self._prepare_proxy(conn)

# Make the request on the httplib connection object.
httplib_response = self._make_request(
conn,
method,
url,
timeout=timeout_obj,
body=body,
headers=headers,
chunked=chunked,
)

# If we're going to release the connection in ``finally:``, then
# the response doesn't need to know about the connection. Otherwise
# it will also try to release it and we'll have a double-release
# mess.
response_conn = conn if not release_conn else None

# Pass method to Response for length checking
response_kw["request_method"] = method

# Import httplib's response into our own wrapper object
response = self.ResponseCls.from_httplib(
httplib_response,
pool=self,
connection=response_conn,
retries=retries,
**response_kw
)

# Everything went great!
clean_exit = True

except EmptyPoolError:
# Didn't get a connection from the pool, no need to clean up
clean_exit = True
release_this_conn = False
raise

except (
TimeoutError,
HTTPException,
SocketError,
ProtocolError,
BaseSSLError,
SSLError,
CertificateError,
) as e:
# Discard the connection for these exceptions. It will be
# replaced during the next _get_conn() call.
clean_exit = False
if isinstance(e, (BaseSSLError, CertificateError)):
e = SSLError(e)
elif isinstance(e, (SocketError, NewConnectionError)) and self.proxy:
e = ProxyError("Cannot connect to proxy.", e)
elif isinstance(e, (SocketError, HTTPException)):
e = ProtocolError("Connection aborted.", e)

> retries = retries.increment(
method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2]
)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\connectionpool.py:726:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = Retry(total=0, connect=None, read=False, redirect=None, status=None), method = 'POST'
url = '/api/v2/workshops/list-by-filter', response = None
error = NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>: Failed to establish a new conne...roperly respond after a period of time, or established connection failed because connected host has failed to respond')
_pool = <urllib3.connectionpool.HTTPSConnectionPool object at 0x000001EF6A105580>
_stacktrace = <traceback object at 0x000001EF69E65F40>

def increment(
self,
method=None,
url=None,
response=None,
error=None,
_pool=None,
_stacktrace=None,
):
""" Return a new Retry object with incremented retry counters.

:param response: A response object, or None, if the server did not
return a response.
:type response: :class:`~urllib3.response.HTTPResponse`
:param Exception error: An error encountered during the request, or
None if the response was received successfully.

:return: A new ``Retry`` object.
"""
if self.total is False and error:
# Disabled, indicate to re-raise the error.
raise six.reraise(type(error), error, _stacktrace)

total = self.total
if total is not None:
total -= 1

connect = self.connect
read = self.read
redirect = self.redirect
status_count = self.status
cause = "unknown"
status = None
redirect_location = None

if error and self._is_connection_error(error):
# Connect retry?
if connect is False:
raise six.reraise(type(error), error, _stacktrace)
elif connect is not None:
connect -= 1

elif error and self._is_read_error(error):
# Read retry?
if read is False or not self._is_method_retryable(method):
raise six.reraise(type(error), error, _stacktrace)
elif read is not None:
read -= 1

elif response and response.get_redirect_location():
# Redirect retry?
if redirect is not None:
redirect -= 1
cause = "too many redirects"
redirect_location = response.get_redirect_location()
status = response.status

else:
# Incrementing because of a server error like a 500 in
# status_forcelist and a the given method is in the whitelist
cause = ResponseError.GENERIC_ERROR
if response and response.status:
if status_count is not None:
status_count -= 1
cause = ResponseError.SPECIFIC_ERROR.format(status_code=response.status)
status = response.status

history = self.history + (
RequestHistory(method, url, error, status, redirect_location),
)

new_retry = self.new(
total=total,
connect=connect,
read=read,
redirect=redirect,
status=status_count,
history=history,
)

if new_retry.is_exhausted():
> raise MaxRetryError(_pool, url, error or ResponseError(cause))
E urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='workshop.simplilearn.com', port=443): Max retries exceeded with url: /api/v2/workshops/list-by-filter (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond'))

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\urllib3\util\retry.py:439: MaxRetryError

During handling of the above exception, another exception occurred:

self = <test_LMS_Regression_Test.TestLMSRegression object at 0x000001EF69C5DC40>, initialize_pages = None
testdata = {'api': '/api/v2/workshops/list-by-filter', 'api_password': 'iamalvcmicroservice', 'api_user': 'nucleus', 'db_type': 'mysql', ...}

@pytest.mark.test_details("SLUB-T18093","high","LMS Regression","Pradeep")
def test_MigrationScript_VerifyClassRegisterationCount(self,initialize_pages,testdata):
'''
Objective : This script is to verify the class data from mysql db and mongo db successfully

Step 01: "Capture the Active session based on category from Jupiter.class table for:
ElearningID,CourseID,WebexSessionID,Max Head Count, Regusteration Count, isSold flag, isWelcome, Cohort_id"
Step 02: "Capture the Active session based on category from Workshop collections from Mongo db table for:
ElearningID,CourseID,WebexSessionID,Max Head Count, Regusteration Count, isSold flag, isWelcome, Cohort_id"
Step 03: "Any discrepancy w.r.t. the session id should be logged for
* Mismatch of isSold Flag
* Mismatch of Registeration Count
* Mismatch of Cohort id"
'''
api_url = pytest.config['api_prod']+testdata['api']
filter_text={'status':1}
> response = requests.post(api_url,data=filter_text,auth=(testdata['api_user'],testdata['api_password']))

test\test_LMS_Regression_Test.py:4965:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\requests\api.py:119: in post
return request('post', url, data=data, json=json, **kwargs)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\requests\api.py:61: in request
return session.request(method=method, url=url, **kwargs)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\requests\sessions.py:530: in request
resp = self.send(prep, **send_kwargs)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\requests\sessions.py:643: in send
r = adapter.send(request, **kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <requests.adapters.HTTPAdapter object at 0x000001EF6A1053A0>, request = <PreparedRequest [POST]>, stream = False
timeout = Timeout(connect=None, read=None, total=None), verify = True, cert = None, proxies = OrderedDict()

def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None):
"""Sends PreparedRequest object. Returns Response object.

:param request: The :class:`PreparedRequest <PreparedRequest>` being sent.
:param stream: (optional) Whether to stream the request content.
:param timeout: (optional) How long to wait for the server to send
data before giving up, as a float, or a :ref:`(connect timeout,
read timeout) <timeouts>` tuple.
:type timeout: float or tuple or urllib3 Timeout object
:param verify: (optional) Either a boolean, in which case it controls whether
we verify the server's TLS certificate, or a string, in which case it
must be a path to a CA bundle to use
:param cert: (optional) Any user-provided SSL certificate to be trusted.
:param proxies: (optional) The proxies dictionary to apply to the request.
:rtype: requests.Response
"""

try:
conn = self.get_connection(request.url, proxies)
except LocationValueError as e:
raise InvalidURL(e, request=request)

self.cert_verify(conn, request.url, verify, cert)
url = self.request_url(request, proxies)
self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)

chunked = not (request.body is None or 'Content-Length' in request.headers)

if isinstance(timeout, tuple):
try:
connect, read = timeout
timeout = TimeoutSauce(connect=connect, read=read)
except ValueError as e:
# this may raise a string formatting error.
err = ("Invalid timeout {}. Pass a (connect, read) "
"timeout tuple, or a single float to set "
"both timeouts to the same value".format(timeout))
raise ValueError(err)
elif isinstance(timeout, TimeoutSauce):
pass
else:
timeout = TimeoutSauce(connect=timeout, read=timeout)

try:
if not chunked:
resp = conn.urlopen(
method=request.method,
url=url,
body=request.body,
headers=request.headers,
redirect=False,
assert_same_host=False,
preload_content=False,
decode_content=False,
retries=self.max_retries,
timeout=timeout
)

# Send the request.
else:
if hasattr(conn, 'proxy_pool'):
conn = conn.proxy_pool

low_conn = conn._get_conn(timeout=DEFAULT_POOL_TIMEOUT)

try:
low_conn.putrequest(request.method,
url,
skip_accept_encoding=True)

for header, value in request.headers.items():
low_conn.putheader(header, value)

low_conn.endheaders()

for i in request.body:
low_conn.send(hex(len(i))[2:].encode('utf-8'))
low_conn.send(b'\r\n')
low_conn.send(i)
low_conn.send(b'\r\n')
low_conn.send(b'0\r\n\r\n')

# Receive the response from the server
try:
# For Python 2.7, use buffering of HTTP responses
r = low_conn.getresponse(buffering=True)
except TypeError:
# For compatibility with Python 3.3+
r = low_conn.getresponse()

resp = HTTPResponse.from_httplib(
r,
pool=conn,
connection=low_conn,
preload_content=False,
decode_content=False
)
except:
# If we hit any problems here, clean up the connection.
# Then, reraise so that we can handle the actual exception.
low_conn.close()
raise

except (ProtocolError, socket.error) as err:
raise ConnectionError(err, request=request)

except MaxRetryError as e:
if isinstance(e.reason, ConnectTimeoutError):
# TODO: Remove this in 3.0.0: see #2811
if not isinstance(e.reason, NewConnectionError):
raise ConnectTimeout(e, request=request)

if isinstance(e.reason, ResponseError):
raise RetryError(e, request=request)

if isinstance(e.reason, _ProxyError):
raise ProxyError(e, request=request)

if isinstance(e.reason, _SSLError):
# This branch is for urllib3 v1.22 and later.
raise SSLError(e, request=request)

> raise ConnectionError(e, request=request)
E requests.exceptions.ConnectionError: HTTPSConnectionPool(host='workshop.simplilearn.com', port=443): Max retries exceeded with url: /api/v2/workshops/list-by-filter (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001EF69D91D60>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond'))

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\requests\adapters.py:516: ConnectionError
Failed test_certificate.py::TestCertificate::test_admin_MPtoCertificate_CertNotConfigured 40.34
self = <test_certificate.TestCertificate object at 0x000001EF69EA7B80>, initialize_pages = None
testdata = {'admin_url': '/admin', 'db_type': 'mysql', 'email': 'admin@simplilearn.com', 'lms_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T7748","high","Program Certificate","Prince")
def test_admin_MPtoCertificate_CertNotConfigured(self,initialize_pages,testdata):

'''
Objective : check on the functionality of program list tab .

Step1: Navigate to Login page..
Step2: Verify redirected to lms admin Page
Step3: Click Program Management then Program List tab
Step4: Click Not Configure MP Program and go to respective certification Tab
Step5: Turn On learning path and configure certificate identifier and save it
Step6: Turn off learning path before logout, so same identifier can be used for other test case

'''

# Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#redirect to admin url then.
browser_url = pytest.config['admin_url']
pytest.driver.get(browser_url)
selenium_helper.wait_for_page_to_load(10,testdata['admin_url'])
time.sleep(2)

# CLicking Program management tab
self.pg_certificate.btn_program_management.click_button()
logging.info("clicked on program management tab")
# CLicking Program list tab
self.pg_certificate.btn_program_list.click_button()
logging.info("clicked on program list tab")

# Clicking PGP Progam not configured here
time.sleep(5)
self.pg_certificate.label_program_search.send_keys('data-science')
time.sleep(5)
> self.pg_certificate.label_MP_notConfigured_program.click_button()

test\test_certificate.py:306:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.certificate_page.CertificatePage object at 0x000001EF6A057880>, loc = 'label_MP_notConfigured_program'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: label_MP_notConfigured_program

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_certificate.py:297 clicked on program management tab INFO  setup:test_certificate.py:300 clicked on program list tab WARNING  setup:page_factory.py:57 the locator label_MP_notConfigured_program on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/admin/program/list is not present
Failed test_certificate.py::TestCertificate::test_admin_UI_verify 5.32
self = <test_certificate.TestCertificate object at 0x000001EF69F82D00>, initialize_pages = None
testdata = {'b2b_certicateprogram': 'Program level certificates', 'b2b_certificationprogram': 'Certification Programs', 'b2b_learningpath': 'Learning paths', 'b2b_masterprogram': "Master's Programs", ...}

@pytest.mark.test_details("SLUB-T7750","high","Program Certificate","Prince")
def test_admin_UI_verify(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click on courses & path and check if all tabs are available or not
Step7: Click Customization -> Preferences option, Program certificate is available or not

'''

# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:437:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_verify_coursePath 5.17
self = <test_certificate.TestCertificate object at 0x000001EF694E9D00>, initialize_pages = None
testdata = {'b2b_MP': 'Master Program', 'b2b_certification': 'Course', 'b2b_certificationprogram': 'Certification Programs', 'b2b_learningPath': '', ...}

@pytest.mark.test_details("SLUB-T7751","high","Program Certificate","Prince")
def test_admin_verify_coursePath(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - Course & Paths

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click on courses & path and check if all tabs are available or not
Step7: Click Certification, Masters, PGP and Learning Path
Step8: Verify if the tab has correct values or not

'''

# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:494:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_verify_MPCertification 5.16
self = <test_certificate.TestCertificate object at 0x000001EF691B7250>, initialize_pages = None
testdata = {'b2b_MP': 'Master Program', 'b2b_certificationprogram': 'Certification Programs', 'b2b_learningpath': 'Learning paths', 'b2b_masterprogram': "Master's Programs", ...}

@pytest.mark.test_details("SLUB-T7752","high","Program Certificate","Prince")
def test_admin_verify_MPCertification(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - Mp SimplilearnDefault configured

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click on courses & path and check if all tabs are available or not
Step7: Click Master's Progam Tab and search for particular id
Step8: Choose simplilearn as certificate
Srep9: Verify the data

'''

# Navigate to Login page.
pytest.driver.delete_all_cookies()
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:578:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_verify_PGPCertification 5.23
self = <test_certificate.TestCertificate object at 0x000001EF6904D730>, initialize_pages = None
testdata = {'b2b_certificationprogram': 'Certification Programs', 'b2b_learningpath': 'Learning paths', 'b2b_masterprogram': "Master's Programs", 'b2b_pgp': 'PG Program', ...}

@pytest.mark.test_details("SLUB-T7753","high","Program Certificate","Prince")
def test_admin_verify_PGPCertification(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - PGP SimplilearnDefault configured

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click on courses & path and check if all tabs are available or not
Step7: Click PGP Program Tab and search for particular id
Step8: Choose simplilearn as certificate
Srep9: Verify the data

'''

# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:685:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_verify_MPCustomCertification 5.21
self = <test_certificate.TestCertificate object at 0x000001EF691B7EB0>, initialize_pages = None
testdata = {'b2b_MP': 'Master Program', 'b2b_certificationprogram': 'Certification Programs', 'b2b_learningpath': 'Learning paths', 'b2b_masterprogram': "Master's Programs", ...}

@pytest.mark.test_details("SLUB-T7754","high","Program Certificate","Prince")
def test_admin_verify_MPCustomCertification(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - Mp CustomCert configured

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click on courses & path and check if all tabs are available or not
Step7: Click Master's Progam Tab and search for particular id
Step8: Choose custom button for certificate
Step9: Fill out the relevant details and save the same
Step10: Verify the data and turn off the certification for further use

'''

# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:765:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_verify_CLPCertification 5.24
self = <test_certificate.TestCertificate object at 0x000001EF6904AE20>, initialize_pages = None
testdata = {'b2b_certificationprogram': 'Certification Programs', 'b2b_learningpath': 'Learning paths', 'b2b_masterprogram': "Master's Programs", 'b2b_pgprogram': 'PG Programs', ...}

@pytest.mark.test_details("SLUB-T7755","high","Program Certificate","Prince")
def test_admin_verify_CLPCertification(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - CLP CustomCert configured

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click on courses & path and check if all tabs are available or not
Step7: Click Learning Path Tab and search for particular id
Step8: Choose custom button for certificate
Step9: Fill out the relevant details and save the same
Step10: Verify the data and turn off the certification for further use

'''
# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:885:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_disable_programCertificate 5.15
self = <test_certificate.TestCertificate object at 0x000001EF688B9670>, initialize_pages = None
testdata = {'b2b_certificationprogram': 'Certification Programs', 'b2b_url': '/apachedev/git/paperclip/public/affiliate', 'email': 'admin@simplilearn.com', 'enterprise_id': '2009', ...}

@pytest.mark.test_details("SLUB-T7757","high","Program Certificate","Prince")
def test_admin_disable_programCertificate(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - ProgramCertificate Disable

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click Customization-> Preferences
Step7: Disable Program level certificate option
'''

# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:997:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_admin_enable_programCertificate 5.16
self = <test_certificate.TestCertificate object at 0x000001EF6A275D60>, initialize_pages = None
testdata = {'b2b_certicateprogram': 'Program level certificates', 'b2b_certificationprogram': 'Certification Programs', 'b2b_url': '/apachedev/git/paperclip/public/affiliate', 'email': 'admin@simplilearn.com', ...}

@pytest.mark.test_details("SLUB-T7756","high","Program Certificate","Prince")
def test_admin_enable_programCertificate(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - ProgramCertificate Enable

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Click Customization-> Preferences
Step7: Enable Program level certificate option
'''

# Navigate to Login page.
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:1058:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_CertMod_B2C_ConfiguredMP_BackenedAssignment 40.05
self = <test_certificate.TestCertificate object at 0x000001EF699B3FA0>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'db_type': 'mysql', 'email': 'admin@simplilearn.com', 'lms_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T7758","high","Program Certificate","Prince")
def test_CertMod_B2C_ConfiguredMP_BackenedAssignment(self,initialize_pages,testdata):

'''
Objective : check on the functionality of Admin UI - ProgramCertificate Enable

Step1: Register a new User
Step2: Login to LMS as admin
Step3: Verify redirected to support URL
Step4: select the program which was configured with certificate in the precondition
Step5: Fill all related information and save successfully with the new user
Step6: Login to LMS with new user registered in precondition
Step7: Fill the onboarding oob page for learner with all information
Step8: Check if Master program Tab is present ot not
Step9: Check if the program name is there or not
Step10: Check if certification tab is present or not
Step11: Verify the same with DB command as well for certification
'''

# Register new user
pytest.driver.delete_all_cookies()
> email_id = TestCertificate.create_newUser(self,testdata)

test\test_certificate.py:1123:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <test_certificate.TestCertificate object at 0x000001EF699B3FA0>
testdata = {'dashboard_url': '/dashboard', 'db_type': 'mysql', 'email': 'admin@simplilearn.com', 'lms_url': '/dashboard', ...}

def create_newUser(self,testdata):

#STEP1: Generate random email and navigate to lms Login url and login with invalid credentials
email = utils.generate_random_email()
pytest.driver.get(pytest.config['url'] + pytest.config['lms_login_url'])

#Step2: Click on signup and verify user redirected to Signup Page
time.sleep(15)
self.pg_login.lnk_signup.click_button()
time.sleep(10)
> assert testdata['signup_url'] in pytest.driver.current_url
E assert '/register' in 'http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile'
E + where 'http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile' = <selenium.webdriver.chrome.webdriver.WebDriver (session="9b3a21781391fdbf94e369f7b18da6d3")>.current_url
E + where <selenium.webdriver.chrome.webdriver.WebDriver (session="9b3a21781391fdbf94e369f7b18da6d3")> = pytest.driver

test\test_certificate.py:42: AssertionError
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator lnk_signup on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present WARNING  setup:page_factory.py:57 the locator lnk_signup on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present
Failed test_certificate.py::TestCertificate::test_CertMod_B2B_MPCertConfigured_ProgramAssignment 5.38
self = <test_certificate.TestCertificate object at 0x000001EF69B30D30>, initialize_pages = None
testdata = {'Big_Data_Hadoop_and_Spark_Developer': 'Big Data Hadoop and Spark Developer', 'Data_Science_Capstone': 'Data Science ...cience_with_Python': 'Data Science with Python', 'Deep_Learning_with_TensorFlow': 'Deep Learning with TensorFlow', ...}

@pytest.mark.test_details("SLUB-T10413","high","Program Certificate","Pradeep")
def test_CertMod_B2B_MPCertConfigured_ProgramAssignment(self,initialize_pages,testdata):
'''
Objective: check on the functionality of Admin UI - ProgramCertificate Enable

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Navigate to Learners Page
Step7: Verify Learners Page
Step8: Add learner Manually
Step9: Verify Add Learner Manually
Step10: Enter Credintials and add Learner
step11: loginto mail box and click on verification link
step12: copy activation link and open
step13: enter details to register in form and click signup
step14: click on skip button on oob form
step15: check master tab and courses assigned
step16: Verify All Present tab

'''

#Step1: Navigate to xenia Login page..
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:1368:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_CertMod_B2B_PGPCertConfigured_ProgramAssignment 5.22
self = <test_certificate.TestCertificate object at 0x000001EF68F43D30>, initialize_pages = None
testdata = {'Big_Data_Hadoop_and_Spark_Developer': 'Big Data Hadoop and Spark Developer', 'Introduction_to_Artificial_Intelligenc...PG Program Certificate', 'Post_Graduate_Program_in_Data_Science_156': 'Post Graduate Program in Data Science-156', ...}

@pytest.mark.test_details("SLUB-T10416","high","Program Certificate","Pradeep")
def test_CertMod_B2B_PGPCertConfigured_ProgramAssignment(self,initialize_pages,testdata):
'''
Objective: check on the functionality of Admin UI - ProgramCertificate Enable

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Navigate to Learners Page
Step7: Verify Learners Page
Step8: Add learner Manually
Step9: Verify Add Learner Manually
Step10: Enter Credintials and add Learner
step11: loginto mail box and click on verification link
step12: copy activation link and open in a new tab
step13: enter details to register in form and click signup
step14: click on skip button on oob form
#step 15: check PG Progran tab and courses assigned

'''

#Step1: Navigate to xenia Login page..
pytest.driver.delete_all_cookies()
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:1560:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_CertMod_B2B_CLPCertConfigured_ProgramAssignment 5.17
self = <test_certificate.TestCertificate object at 0x000001EF68F4A0D0>, initialize_pages = None
testdata = {'Big_Data_Hadoop_and_Spark_Developer_clp': 'Big Data Hadoop and Spark Developer', 'Profile_Details_Check_CLP': 'Profi...e_page': 'Profile Details Check CLP', 'add_learner_url': '/apachedev/git/paperclip/public/affiliate/learner/view', ...}

@pytest.mark.test_details("SLUB-T10417","high","Program Certificate","Pradeep")
def test_CertMod_B2B_CLPCertConfigured_ProgramAssignment(self,initialize_pages,testdata):
'''
Objective: check on the functionality of Admin UI - ProgramCertificate Enable

Step1: Navigate to xenia Login page..
Step2: Verify redirected to Xenia Page
Step3: Click FIN Sale-> Enterprise Plans-> View All Enterprises
Step4: Click Particular GID is present and then login as manager for same
Step5: Verify redirected to b2b Page as manager
Step6: Navigate to Learners Page
Step7: Verify Learners Page
Step8: Add learner Manually
Step9: Verify Add Learner Manually
Step10: Enter Credintials and add Learner
step11: loginto mail box and click on verification link
step12: copy activation link and open in a new tab
step13: enter details to register in form and click signup
step14: click on clp program tab and verify

'''

#Step1: Navigate to xenia Login page..
> lms_login_helper.xenia_login(testdata['email'],testdata['password'])

test\test_certificate.py:1737:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:70: in xenia_login
pytest.driver.get(pytest.config['xenia_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_CertMod_B2B_ConfiguredMP_CertificationTab_LockedCourses_and_Program_UIVerification 2.33
self = <test_certificate.TestCertificate object at 0x000001EF6969FB20>, initialize_pages = None
testdata = {'course_certificate_template': 'Locked', 'dashboard': '/dashboard', 'dashboard_url': '/dashboard', 'email': 'simplilearnautomation+qbn@yopmail.com', ...}

@pytest.mark.test_details("SLUB-T10421","high","Program Certificate","Pradeep")
def test_CertMod_B2B_ConfiguredMP_CertificationTab_LockedCourses_and_Program_UIVerification(self,initialize_pages,testdata):

'''
step 01: login as a learner
step 02: verify the Master program tab
STEP 03: verify the program which was assigned
STEP 04: Click on Start program CTA
step 05: Verify the certification tab
step 06: Capture the courses present under Courses tab
Step 07: Capture the Courses present in electives tab
Step 08: Navigate to Certification tab
Step 09: Verify the courses list under Program certificate to be same as that from courses tab
Step 10: Verify the courses list under Electives to be sames as Electives tab
Step 11: verify the course certificate template overlay
Step 12: verify the program level certificate template
Step 13: verify the locked screen
Step 14: verify the pending courses count

'''
#step01: login as a learner
> pytest.driver.get(pytest.config['b2b_learner_login'])

test\test_certificate.py:2228:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_CertMod_B2B_ConfiguredPGP_CertificationTab_LockedCourses_and_Program_UIVerification 2.21
self = <test_certificate.TestCertificate object at 0x000001EF6969F2B0>, initialize_pages = None
testdata = {'course_certificate_template': 'Locked', 'dashboard': '/dashboard', 'dashboard_url': '/dashboard', 'email': 'simplilearnautomation+hyv@yopmail.com', ...}

@pytest.mark.test_details("SLUB-T10422","high","Program Certificate","Pradeep")
def test_CertMod_B2B_ConfiguredPGP_CertificationTab_LockedCourses_and_Program_UIVerification(self,initialize_pages,testdata):
'''
Step 01: Login as the learner
Step 02: verify the PG program tab
Step 03: verify the program which was assigned
Step 04: Click on Start program CTA
Step 05: Verify the certification tab
Step 06: Capture the courses present under Courses tab
Step 07: Capture the course present under Prerequitie tab
Step 08: Capture the Courses present in electives tab
Step 09: Navigate to Certification tab
Step 10: Verify the courses list under Program certificate to be same as that from courses tab
Step 11: Verify the courses list under prerequite tab to be sames as Electives tab
Step 12: Verify the courses list under Electives to be sames as Electives tab
Step 13: verify the course certificate template overlay
Step 14: verify the program level certificate template
Step 15: verify the locked screen
Step 16: verify the pending courses count

'''

#step01: login as a learner
> pytest.driver.get(pytest.config['b2b_learner_login'])

test\test_certificate.py:2366:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_certificate.py::TestCertificate::test_CertMod_B2B_ConfiguredCLP_CertificationTab_LockedCourse_and_Program_UIVerification 2.23
self = <test_certificate.TestCertificate object at 0x000001EF6A14AD30>, initialize_pages = None
testdata = {'course_certificate_template': 'Locked', 'dashboard': '/dashboard', 'dashboard_url': '/dashboard', 'email': 'simplilearnautomation+aqt@yopmail.com', ...}

@pytest.mark.test_details("SLUB-T10442","high","Program Certificate","Pradeep")
def test_CertMod_B2B_ConfiguredCLP_CertificationTab_LockedCourse_and_Program_UIVerification(self,initialize_pages,testdata):
'''
Step 01: Login as the learner
Step 02: verify the learning PAth tab
Step 03: verify the program which was assigned
Step 04: Click on Start program CTA
Step 05: Verify the certification tab
Step 06: Capture the courses present under Courses tab
Step 07: Capture the course present under Aditional Courses tab
Step 08: Navigate to Certification tab
Step 09: Verify the courses list under Program certificate to be same as that from courses tab
Step 10: Verify the courses list under Aditional Courses to be sames as Aditional Courses
Step 11: verify the course certificate template overlay
Step 12: verify the program level certificate template
Step 13: verify the locked screen
Step 14: verify the pending courses count
'''
#Step 01: Login as the learner
> pytest.driver.get(pytest.config['b2b_learner_login'])

test\test_certificate.py:2522:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"unknown error","message":"unknown error: net::ERR_CONNECTION_REFUSED\\n ...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: WebDriverException
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCCohortClass_ClassCreation_MultipleSession 0.00
self = <test_cohort.TestCohort object at 0x000001EF6A313460>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6369","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCCohortClass_ClassCreation_MultipleSession(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the GLVC cohort class is created successfully and displayed correctly to the cohort user.

#STEP 1: call the engagex test case
#STEP 2; read the data from engagex
#STEP 3: Navigate to Login page.
#STEP 4: go to live classes
#STEP 5: check the given course is available
#STEP 6: logout from user

'''

#STEP 1: call the engagex test case
> CallEngagex().create_glvc_cohort_with_multiple_session()

test\test_cohort.py:61:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <helper.integration_helper.CallEngagex object at 0x000001EF6A314B80>

def create_glvc_cohort_with_multiple_session(self):

original_path=os.getcwd()
> os.chdir(r"../engagex_test_python")
E FileNotFoundError: [WinError 2] The system cannot find the file specified: '../engagex_test_python'

helper\integration_helper.py:11: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_CohortClassfromDifferentCohort_ClassNotDisplayed 22.30
self = <test_cohort.TestCohort object at 0x000001EF6A313A00>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3921', 'email': 'iris_apollo843@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6370","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_CohortClassfromDifferentCohort_ClassNotDisplayed(self,initialize_pages,testdata):

'''
Objective : This test is to verify that use having same program but different cohort,should not be able to see the classes to register belong wo another cohort

#STEP 1:login and wait for all element to load
#STEP 2; read the data from engagex
#STEP 3: go to live classes
#STEP 4: check all the validation that course is expired and user not able to register for class
#STEP 5: logout from user

'''

# STEP 1:login and wait for all element to load
lms_login_helper.login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(30,testdata['home_url'])

#STEP 2; read the data from engagex
> json_object=self.pg_liveclass.readDataFromEngagex()

test\test_cohort.py:99:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF69C0C580>

def readDataFromEngagex(self):
original_path=os.getcwd()
> os.chdir(r"../engagex_test_python/test/Integration Output")
E FileNotFoundError: [WinError 3] The system cannot find the path specified: '../engagex_test_python/test/Integration Output'

pages\liveclasses_page.py:38: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_ValidCourse_ClassDisplayed 0.00
self = <test_cohort.TestCohort object at 0x000001EF6A1BF6A0>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6371","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_ValidCourse_ClassDisplayed(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the cohort GLVC class should be available to user , so that user can select the class to register.

#STEP 1: read the data from engagex
#STEP 2: Navigate to Login page.
#STEP 3: go to live classes
#STEP 4: check the given course is available
#STEP 5: logout from user

'''
#STEP 1; read the data from engagex
> json_object=self.pg_liveclass.readDataFromEngagex()

test\test_cohort.py:125:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF6A036D90>

def readDataFromEngagex(self):
original_path=os.getcwd()
> os.chdir(r"../engagex_test_python/test/Integration Output")
E FileNotFoundError: [WinError 3] The system cannot find the path specified: '../engagex_test_python/test/Integration Output'

pages\liveclasses_page.py:38: FileNotFoundError
Failed test_cohort.py::TestCohort::test_lvc_integrationtest_glvccohortclass_register_passed 0.00
self = <test_cohort.TestCohort object at 0x000001EF68F5EA00>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6372","high","Cohort","Himanshu")
def test_lvc_integrationtest_glvccohortclass_register_passed(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the cohort GLVC class should be available to the user and the user is able to register for the class successfully

#STEP 1: call the engagex test case
#STEP 2: read the data from engagex
#STEP 3:login and wait for all element to load
#STEP 4: go to live classes
#STEP 5: return the index of class
#STEP 6: click on registration button
#STEP 7: switch to alert and complete the registration
#STEP 8: logout from user
#STEP 9: call the engagex test case
#STEP 10: read the data from engagex
#STEP 11: check the registration count has been increase

'''
#STEP 1: call the engagex test case
> CallEngagex().get_the_registration_count_for_glvc_cohort()

test\test_cohort.py:161:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <helper.integration_helper.CallEngagex object at 0x000001EF68F7D0D0>

def get_the_registration_count_for_glvc_cohort(self):

original_path=os.getcwd()
> os.chdir(r"../engagex_test_python")
E FileNotFoundError: [WinError 2] The system cannot find the file specified: '../engagex_test_python'

helper\integration_helper.py:19: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_Attend_Passed 76.12
self = <test_cohort.TestCohort object at 0x000001EF6A34ECD0>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6374","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_Attend_Passed(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the user should be able to attend the GLVC class successfully

#STEP 1:login and wait for all element to load
#STEP 2: go to live classes
#STEP 3: check go to button is present
#STEP 4: logout from user

'''

# STEP 1:login and wait for all element to load
lms_login_helper.login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(30,testdata['home_url'])

#refreshing page again
pytest.driver.refresh()
selenium_helper.wait_for_page_to_load(30,testdata['home_url'])

#STEP 2: go to live classes
self.pg_liveclass.goToLiveClasses(testdata['elearning_id_url'],testdata['course_url'])


if(selenium_helper.is_element_present(self.pg_liveclass.locators["btn_go_to_class"][0],20)):
#STEP 3: check go to button is present
assert selenium_helper.is_element_present(self.pg_liveclass.locators["btn_go_to_class"][0],10)

#STEP 4: logout from user
> self.pg_liveclass.backAndLogout()

test\test_cohort.py:238:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pages\liveclasses_page.py:80: in backAndLogout
self.btn_back.click_button()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF69546B50>, loc = 'btn_back'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: btn_back

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[title='Available Classes']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3920/Phase-2---Mean/classes is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "button[title='Attend']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3920/Phase-2---Mean/classes is not present WARNING  setup:page_factory.py:57 the locator btn_back on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3920/Phase-2---Mean/classes is not present
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_SoldOutTrigger 0.00
self = <test_cohort.TestCohort object at 0x000001EF68F7DAF0>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_apollo843@yopmail.com', 'email2': 'ccr50@yopmail.com', ...}

@pytest.mark.test_details("SLUB-T6375","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_SoldOutTrigger(self,initialize_pages,testdata):

'''
Objective : This test is to verify that when the class registration count reaches the max head count, then the class should be marked as sold out

#STEP 1: read the data from engagex
#STEP 2:login and wait for all element to load
#STEP 3: go to live classes
#STEP 4: click on unregistration button
#STEP 5: unregister from the class
#STEP 6: return the index of class
#STEP 7: click on registration button
#STEP 8: switch to alert and complete the registration
#STEP 9: logout from user
#STEP 10: call the engagex test case
#STEP 11: call the engagex test case
#STEP 12: read the data from engagex
#STEP 13:login and wait for all element to load
#STEP 14: go to live classes
#STEP 15: logout from user

'''

#STEP 1: read the data from engagex
> json_object=self.pg_liveclass.readDataFromEngagex()

test\test_cohort.py:295:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF6A1549D0>

def readDataFromEngagex(self):
original_path=os.getcwd()
> os.chdir(r"../engagex_test_python/test/Integration Output")
E FileNotFoundError: [WinError 3] The system cannot find the path specified: '../engagex_test_python/test/Integration Output'

pages\liveclasses_page.py:38: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_SoldOutClasstoAvailableClass 0.00
self = <test_cohort.TestCohort object at 0x000001EF6A1D87C0>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_apollo843@yopmail.com', 'email2': 'ccr50@yopmail.com', ...}

@pytest.mark.test_details("SLUB-T6376","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_SoldOutClasstoAvailableClass(self,initialize_pages,testdata):

'''
Objective : This test is to verify that when the class registration count reaches less the max head count, then the class should not be shown as sold out and it becomes available for other users for the registeration

#STEP 1: read the data from engagex
#STEP 2:login and wait for all element to load
#STEP 3: go to live classes
#STEP 4: click on unregistration button
#STEP 5: unregister from the class
#STEP 6: return the index of class
#STEP 7: click on registration button
#STEP 8: switch to alert and complete the registration
#STEP 9: logout from user
#STEP 10: call the engagex test case
#STEP 11: call the engagex test case
#STEP 12: read the data from engagex
#STEP 13:login and wait for all element to load
#STEP 14: go to live classes
#STEP 15: logout from user

'''

#STEP 1: read the data from engagex
> json_object=self.pg_liveclass.readDataFromEngagex()

test\test_cohort.py:375:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF6976E730>

def readDataFromEngagex(self):
original_path=os.getcwd()
> os.chdir(r"../engagex_test_python/test/Integration Output")
E FileNotFoundError: [WinError 3] The system cannot find the path specified: '../engagex_test_python/test/Integration Output'

pages\liveclasses_page.py:38: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_Unregister_Passed 0.00
self = <test_cohort.TestCohort object at 0x000001EF6A2D60A0>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6373","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_Unregister_Passed(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the user should be able to unregister the GLVC class successfully.

#STEP 1: call the engagex test case
#STEP 2: read the data from engagex
#STEP 3:login and wait for all element to load
#STEP 4: go to live classes
#STEP 5: click on unregistration button
#STEP 6: unregister from the class
#STEP 7: logout from user
#STEP 8: call the engagex test case
#STEP 9: read the data from engagex
#STEP 10: check the registration count has been increase

'''
#STEP 1: call the engagex test case
> CallEngagex().get_the_registration_count_for_glvc_cohort()

test\test_cohort.py:455:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <helper.integration_helper.CallEngagex object at 0x000001EF6A2AC910>

def get_the_registration_count_for_glvc_cohort(self):

original_path=os.getcwd()
> os.chdir(r"../engagex_test_python")
E FileNotFoundError: [WinError 2] The system cannot find the file specified: '../engagex_test_python'

helper\integration_helper.py:19: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_SessionCancellation_InitialSessions 0.00
self = <test_cohort.TestCohort object at 0x000001EF69788BB0>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6377","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_SessionCancellation_InitialSessions(self,initialize_pages,testdata):

'''
Objective : This test is to verify that when few sessions are cancelled for the class, then there should not be any impact on placement of the class card while the cancelled dates should be marked as cancelled on the class card.

#STEP 1: call the engagex test case
#STEP 2; read the data from engagex
#STEP 3: Navigate to Login page.
#STEP 4: go to live classes
#STEP 5: check the given course is available
#STEP 6: logout from user

'''

#STEP 1: call the engagex test case
> CallEngagex().cancel_few_session_of_glvc_cohort()

test\test_cohort.py:507:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <helper.integration_helper.CallEngagex object at 0x000001EF6A3C8880>

def cancel_few_session_of_glvc_cohort(self):

original_path=os.getcwd()
> os.chdir(r"../engagex_test_python")
E FileNotFoundError: [WinError 2] The system cannot find the file specified: '../engagex_test_python'

helper\integration_helper.py:35: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_ClassCancellation 0.00
self = <test_cohort.TestCohort object at 0x000001EF6A2ACB20>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6378","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_ClassCancellation(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the GLVC cohort class is created successfully and displayed correctly to the cohort user.

#STEP 1: call the engagex test case
#STEP 2; read the data from engagex
#STEP 3: Navigate to Login page.
#STEP 4: go to live classes
#STEP 5: check the given course is available
#STEP 6: logout from user

'''

#STEP 1: call the engagex test case
> CallEngagex().cancel_glvc_cohort_class()

test\test_cohort.py:560:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <helper.integration_helper.CallEngagex object at 0x000001EF6A2FD760>

def cancel_glvc_cohort_class(self):

original_path=os.getcwd()
> os.chdir(r"../engagex_test_python")
E FileNotFoundError: [WinError 2] The system cannot find the file specified: '../engagex_test_python'

helper\integration_helper.py:43: FileNotFoundError
Failed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_Creation_SingleSession 0.00
self = <test_cohort.TestCohort object at 0x000001EF6A2E3100>, initialize_pages = None
testdata = {'course_url': '/Phase-2---Mean/classes', 'elearning_id_url': '/courses/3920', 'email': 'iris_al7@yopmail.com', 'home_url': '/dashboard', ...}

@pytest.mark.test_details("SLUB-T6379","high","Cohort","Himanshu")
def test_LVC_IntegrationTest_GLVCcohortClass_Creation_SingleSession(self,initialize_pages,testdata):

'''
Objective : This test is to verify that the GLVC class is created successfully and displayed correctly to the cohort user.

#STEP 1: call the engagex test case
#STEP 2; read the data from engagex
#STEP 3: Navigate to Login page.
#STEP 4: go to live classes
#STEP 5: check the given course is available
#STEP 6: logout from user

'''

#STEP 1: call the engagex test case
> CallEngagex().create_glvc_cohort_with_single_session()

test\test_cohort.py:597:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <helper.integration_helper.CallEngagex object at 0x000001EF6A435A60>

def create_glvc_cohort_with_single_session(self):

original_path=os.getcwd()
> os.chdir(r"../engagex_test_python")
E FileNotFoundError: [WinError 2] The system cannot find the file specified: '../engagex_test_python'

helper\integration_helper.py:51: FileNotFoundError
Failed test_community_btn.py::TestCommunityBtn::test_community_as_PG_user_in_program_detail_page 60.33
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A435880>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'email': 'atlascomfeb14t1@yopmail.com', 'password': 'Simpli@123', 'program_url': '/program/post-graduates', ...}

@pytest.mark.test_details("SLUB-T17218", "Normal", "Community", "Om")
def test_community_as_PG_user_in_program_detail_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C PG user, click on community from Program detail page, community page should be displayed
Step 1: Login to paperclip as B2C PG user, click on any pg course, Go to program button
Step 2: Click on community from program detail page
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on the 'Go To Program' Button
self.pg_community.go_to_program_btn.click_button()
selenium_helper.wait_for_page_to_load(50, testdata['program_url'])
default_handle = pytest.driver.current_window_handle
# Click on the 'Community' Button
self.pg_community.community_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
time.sleep(5)
> assert testdata['username'] == self.pg_community.username_btn.get_text()

test\test_community_btn.py:41:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF6A4E2D00>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator username_btn on url https://devcommunity.simplilearn.com/ is not present
Failed test_community_btn.py::TestCommunityBtn::test_community_as_non_PG_user_in_dashboard_page 36.90
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A435040>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'email': 'b2capollo@yopmail.com', 'password': 'Simpli@123', 'username': 'b2capollo'}

@pytest.mark.test_details("SLUB-T17219", "Normal", "Community", "Om")
def test_community_as_non_PG_user_in_dashboard_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C non-PG user, click on community from dashboard, community page should be displayed
Step 1: Login to paperclip as B2C non-PG user
Step 2: Click on community from dashboard
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
default_handle = pytest.driver.current_window_handle
# Click on the 'Community' Button
self.pg_community.community_btn.click_button()
logging.info("Successfully clicked on community button")
handles = list(pytest.driver.window_handles)
for handle in handles:
if default_handle != handle:
pytest.driver.switch_to.window(handle)
time.sleep(5)
> assert testdata['username'] == self.pg_community.username_btn.get_text(
)

test\test_community_btn.py:72:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF6A505D90>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
INFO  setup:test_community_btn.py:66 Successfully clicked on community button WARNING  setup:page_factory.py:57 the locator username_btn on url http://dockerv5.simplilearn.com:8082/apachedev/git/paperclip/public/program/post-graduates/156/Post%20Graduate%20Program%20in%20Data%20Science/courses is not present
Failed test_community_btn.py::TestCommunityBtn::test_community_as_non_PG_user_in_learning_page 86.06
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A5005E0>, initialize_pages = None
testdata = {'courses_url': '/courses/syllabus', 'dashboard_url': '/dashboard', 'email': 'b2capollo@yopmail.com', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T17220", "Normal", "Community", "Om")
def test_community_as_non_PG_user_in_learning_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C non-PG user, click on community from learning environment, community page should be displayed
Step 1: Login to paperclip as B2C non-PG user, click on course
Step 2: Click on community from learning environment
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on the 'Courses' Button
self.pg_community.courses_btn.click_button()
default_handle = pytest.driver.current_window_handle
selenium_helper.wait_for_page_to_load(50, testdata['courses_url'])
# Click on the 'Community' Button
self.pg_community.community_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
time.sleep(5)
> assert testdata['username'] == self.pg_community.username_btn.get_text()

test\test_community_btn.py:105:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF6A506D90>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator username_btn on url http://dockerv5.simplilearn.com:8082/apachedev/git/paperclip/public/dashboard is not present
Failed test_community_btn.py::TestCommunityBtn::test_community_as_PG_user_in_dashboard_page 33.69
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A506880>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'email': 'atlascomfeb14t1@yopmail.com', 'password': 'Simpli@123', 'username': 'dkdmshb'}

@pytest.mark.test_details("SLUB-T17221", "Normal", "Community", "Om")
def test_community_as_PG_user_in_dashboard_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C PG user, click on community from dashboard page, community page should be displayed
Step 1: Login to paperclip as B2C PG user
Step 2: Click on community from dashboard
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
default_handle = pytest.driver.current_window_handle
# Click on the 'Community' Button
self.pg_community.community_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
time.sleep(5)
> assert testdata['username'] == self.pg_community.username_btn.get_text()

test\test_community_btn.py:134:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF6A5C98B0>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator username_btn on url http://dockerv5.simplilearn.com:8082/apachedev/git/paperclip/public/dashboard is not present
Failed test_community_btn.py::TestCommunityBtn::test_community_as_PG_user_in_learning_page 112.09
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A5C9790>, initialize_pages = None
testdata = {'courses_url': '/courses/syllabus', 'dashboard_url': '/dashboard', 'email': 'atlascomfeb14t1@yopmail.com', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T17222", "Normal", "Community", "Om")
def test_community_as_PG_user_in_learning_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C PG user, click on community from learning environment, community page should be displayed
Step 1: Login to paperclip as B2C PG user, click on any pg course, go too button
Step 2: Click on community from learning environment
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on the 'Go To Program' Button
self.pg_community.go_to_program_btn.click_button()
selenium_helper.wait_for_page_to_load(50, testdata['program_url'])
# Click on 'Courses' Tab
self.pg_community.course_tab_btn.click_button()
# Click on 'Courses' Button
self.pg_community.PG_user_courses_btn.click_button()
default_handle = pytest.driver.current_window_handle
selenium_helper.wait_for_page_to_load(50, testdata['courses_url'])
# Click on the 'Community' Button
self.pg_community.community_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
time.sleep(10)
> assert testdata['username'] == self.pg_community.username_btn.get_text()

test\test_community_btn.py:172:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF6A5C9490>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator username_btn on url http://dockerv5.simplilearn.com:8082/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present
Failed test_community_btn.py::TestCommunityBtn::test_community_as_non_PG_user_in_profile_page 38.39
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A14B640>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'email': 'b2capollo@yopmail.com', 'password': 'Simpli@123', 'username': 'b2capollo'}

@pytest.mark.test_details("SLUB-T17223", "Normal", "Community", "Om")
def test_community_as_non_PG_user_in_profile_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C non-PG user, click on community from profile page, community page should be displayed
Step 1: Login to paperclip as B2C non-PG user, click on profile
Step 2: Click on community from profile page
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on 'Profile' Dropdown
self.pg_community.profile_dropdown_btn.click_button()
time.sleep(3)
default_handle = pytest.driver.current_window_handle
self.pg_community.profile_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
# Click on the 'Community' Button
self.pg_community.profile_community_btn.click_button()
pytest.driver.close()
all_handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(all_handles[1])
time.sleep(5)
> assert testdata['username'] == self.pg_community.username_btn.get_text()

test\test_community_btn.py:209:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF69F13AF0>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator username_btn on url https://devcommunity.simplilearn.com/ is not present
Failed test_community_btn.py::TestCommunityBtn::test_community_as_PG_user_in_profile_page 39.03
self = <test_community_btn.TestCommunityBtn object at 0x000001EF6A5F22E0>, initialize_pages = None
testdata = {'courses_url': '/courses/syllabus', 'dashboard_url': '/dashboard', 'email': 'atlascomfeb14t1@yopmail.com', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T17224", "Normal", "Community", "Om")
def test_community_as_PG_user_in_profile_page(self, initialize_pages, testdata):
'''
Objective: Login to paperclip as B2C PG user, click on community from profile page, community page should be displayed
Step 1: Login to paperclip as B2C PG user, click on profile
Step 2: Click on community from profile page
'''

# Navigate to lms and login with valid credentials
lms_login_helper.community_user_login(
testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on 'Profile' Dropdown
self.pg_community.profile_dropdown_btn.click_button()
time.sleep(3)
default_handle = pytest.driver.current_window_handle
# Click on 'Profile' button
self.pg_community.profile_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
# Click on the 'Community' Button
self.pg_community.profile_community_btn.click_button()
pytest.driver.close()
all_handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(all_handles[1])
time.sleep(5)
> assert testdata['username'] == self.pg_community.username_btn.get_text()

test\test_community_btn.py:247:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.communitybtn_page.CommunityUserPage object at 0x000001EF69F30CD0>, loc = 'username_btn'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: username_btn

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator username_btn on url https://devcommunity.simplilearn.com/forums/agile-and-scrum-certification-forum.242/ is not present
Failed test_elearningpagetab.py::TestElearningPageTab::test_elearningpage_visibility 65.26
self = <test_elearningpagetab.TestElearningPageTab object at 0x000001EF6A51D940>, initialize_pages = None
testdata = {'elearningpage_url': '/courses', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T1432","high","Elearning Tab","Yachana")
def test_elearningpage_visibility(self,initialize_pages,testdata):


'''
Objective : check on the functionality of elearning tab .

Step1: Navigate to Login page..
Step2: Verify user redirected to Forgot Password Page
Step3: Enter all the details of existing user on Forgot Password Page and click on send button .

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#Step3: Click on Course tab .
selenium_helper.is_element_present(self.pg_home.locators["certificate_program"][0],20)
self.pg_home.certificate_program.click_button()


#Step 4: Click on First course
self.pg_elearning.hover_to_first_course.click_button()

#wait to load elearning page
selenium_helper.wait_for_page_to_load(30,testdata['elearningpage_url'])

# verify following tabs are present or not
# 1. Back 2. Help 3. Notes 4. Community 5. Self Learning

assert self.pg_elearning.back.is_displayed(), " Back tab not displayed after landing to elearning page"

assert self.pg_elearning.help.is_displayed(), " Help tab not displayed after landing to elearning page"

assert self.pg_elearning.notes.is_displayed(), " Notes tab not displayed after landing to elearning page"

> assert self.pg_elearning.community.is_displayed(), "Community tab not displayed landing to elearning page"
E AssertionError: Community tab not displayed landing to elearning page
E assert False
E + where False = <bound method WebElement.is_displayed of <selenium.webdriver.remote.webelement.WebElement (session="9b3a21781391fdbf94e369f7b18da6d3", element="7624c7b6-1f0a-4ab9-9a33-503b4c965372")>>()
E + where <bound method WebElement.is_displayed of <selenium.webdriver.remote.webelement.WebElement (session="9b3a21781391fdbf94e369f7b18da6d3", element="7624c7b6-1f0a-4ab9-9a33-503b4c965372")>> = <selenium.webdriver.remote.webelement.WebElement (session="9b3a21781391fdbf94e369f7b18da6d3", element="7624c7b6-1f0a-4ab9-9a33-503b4c965372")>.is_displayed
E + where <selenium.webdriver.remote.webelement.WebElement (session="9b3a21781391fdbf94e369f7b18da6d3", element="7624c7b6-1f0a-4ab9-9a33-503b4c965372")> = <pages.elearningpagetab.ElearningPageTab object at 0x000001EF6A4C2700>.community
E + where <pages.elearningpagetab.ElearningPageTab object at 0x000001EF6A4C2700> = <test_elearningpagetab.TestElearningPageTab object at 0x000001EF6A51D940>.pg_elearning

test\test_elearningpagetab.py:60: AssertionError
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator hover_to_first_course on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present WARNING  setup:page_factory.py:57 the locator community on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3128/Big-Data-Hadoop-Administrator-Course-Live/syllabus is not present WARNING  setup:page_factory.py:66 the locator community on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3128/Big-Data-Hadoop-Administrator-Course-Live/syllabus is not visible
Failed test_elvc.py::TestElvc::test_myclasses_progress_soon_tag 379.40
self = <test_elvc.TestElvc object at 0x000001EF6A60EF10>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4033","high","Elvc","Himanshu")
def test_myclasses_progress_soon_tag(self,initialize_pages,testdata):

'''
Objective : To check if progess tag is present then starting date must be less than the current date and end date must be greater than current date

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: get name of details of class
STEP 5: if the class is in progress
STEP 6: get the date and timings of classes
STEP 7: get today's day and put the date in datatime
STEP 8: check if the starting date is less than current date and end date is greater then current date

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

#refreshing page again
pytest.driver.refresh()
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

#STEP 3: go to the liveclasses
selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],40)
self.pg_liveclass.liveclasses.click_button()
#wait for page to load
if(selenium_helper.is_element_present(self.pg_availableclass.locators["class_name"][0],40)==True):

#STEP 4: get name of details of class
CourseName=self.pg_availableclass.class_name.get_text()
status='Progress'

#STEP 5: if the class is in progress
if(status in CourseName):

#STEP 6: get the date and timings of classes
date=self.pg_availableclass.date_time_class.get_text().split(" ")

#get the starting date and end date
StartDate=date[1].split(",")
EndDate=date[5].split(",")
#convert the months to integer
StartMonth=self.pg_availableclass.monthToNum(date[0])
EndMonth=self.pg_availableclass.monthToNum(date[4])

#STEP 7: get today's day and put the date in datatime
StartingCourseDate = datetime.datetime(int(date[2]), int(StartMonth), int(StartDate[0]))
EndingCourseDate = datetime.datetime(int(date[2]), int(EndMonth), int(EndDate[0]))
CurrentDate = datetime.datetime.now()

#STEP 8: check if the starting date is less than current date and end date is greater then current date
assert (StartingCourseDate<CurrentDate and CurrentDate<EndingCourseDate)
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_elvc.py:533:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:56: in logout
pg_home.logout()
pages\home_page.py:18: in logout
self.lnk_logout.execute_script(script)
core\page_factory.py:334: in execute_script
return self.parent.execute_script(script, self)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:634: in execute_script
return self.execute(command, {
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Failed test_elvc.py::TestElvc::test_my_class_button_present 343.76
self = <test_elvc.TestElvc object at 0x000001EF6A853970>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4033","high","Elvc","Himanshu")
def test_my_class_button_present(self,initialize_pages,testdata):

'''
Objective : To check the my class button is present

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: to check the my class present

'''
#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#STEP 2: redirected to course

url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

#refreshing page again
pytest.driver.refresh()
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],40)
#STEP 3: go to the liveclasses
self.pg_liveclass.liveclasses.click_button()
#wait for page to load
time.sleep(5)

#STEP 4: to check the my class present
assert selenium_helper.is_element_present(self.pg_liveclass.locators["my_classes"][0],40) ==True
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_elvc.py:612:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:56: in logout
pg_home.logout()
pages\home_page.py:18: in logout
self.lnk_logout.execute_script(script)
core\page_factory.py:334: in execute_script
return self.parent.execute_script(script, self)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:634: in execute_script
return self.execute(command, {
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
Failed test_elvc.py::TestElvc::test_class_registration_policy_button_present 300.04
self = <test_elvc.TestElvc object at 0x000001EF6A6CD5E0>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4033","high","Elvc","Himanshu")
def test_class_registration_policy_button_present(self,initialize_pages,testdata):

'''
Objective : To check the class_registration_policy button is present

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: to check the availabe class present

'''
#Step1: Navigate to Login page.
> lms_login_helper.login(testdata['email'],testdata['password'])

test\test_elvc.py:667:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:25: in login
pytest.driver.get(pytest.config['url'] + pytest.config['lms_login_url'])
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:333: in get
self.execute(Command.GET, {'url': url})
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: -...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: -0.008
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
Failed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_myclasses_starting_soon_tag 395.53
self = <test_elvc_1536_864_resolution.TestElvc1536Resolution object at 0x000001EF6A7774C0>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T3973","high","Elvc1536Resolution","Himanshu")
def test_myclasses_starting_soon_tag(self,initialize_pages,testdata):

'''
Objective : To check if starting tag is present the starting date must be greater than the current date

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: get name of details of class
STEP 5: if the class is starting soon
STEP 6: get the date and timings of classes
STEP 7: get today's day and put the date in datatime
STEP 8: check if the starting date is greater than current date

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(40,testdata['lms_url'])
pytest.driver.set_window_size(1536,864)

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

#refreshing page again
pytest.driver.refresh()
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

#STEP 3: go to the liveclasses
selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],40)
self.pg_liveclass.liveclasses.click_button()
#wait for page to load
if(selenium_helper.is_element_present(self.pg_availableclass.locators["class_name"][0],10)==True):

#STEP 4: get name of details of class
CourseName=self.pg_availableclass.class_name.get_text()
status='Starting Soon'

#STEP 5: if the class is starting soon
if(status in CourseName):

#STEP 6: get the date and timings of classes
date=self.pg_availableclass.date_time_class.get_text().split(" ")
#get the startin date
StartDate=date[1].split(",")
#convert he starting month to integer
StartMonth=self.pg_availableclass.monthToNum(date[0])

#STEP 7: get today's day and put the date in datatime
StartingCourseDate = datetime.datetime(int(date[2]), int(StartMonth), int(StartDate[0]))
CurrentDate = datetime.datetime.now()

#STEP 8: check if the starting date is greater than current date
assert (StartingCourseDate>CurrentDate)
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_elvc_1536_864_resolution.py:465:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:63: in logout
pytest.driver.delete_all_cookies()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:878: in delete_all_cookies
self.execute(Command.DELETE_ALL_COOKIES)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Failed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_my_class_button_present 392.99
self = <test_elvc_1536_864_resolution.TestElvc1536Resolution object at 0x000001EF6A814B20>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4033","high","Elvc1536Resolution","Himanshu")
def test_my_class_button_present(self,initialize_pages,testdata):

'''
Objective : To check the my class button is present

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: to check the my class present

'''
#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(40,testdata['lms_url'])
pytest.driver.set_window_size(1536,864)

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],40)
#STEP 3: go to the liveclasses
self.pg_liveclass.liveclasses.click_button()
#wait for page to load
time.sleep(5)

#STEP 4: to check the my class present
assert selenium_helper.is_element_present(self.pg_liveclass.locators["my_classes"][0],40) ==True
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_elvc_1536_864_resolution.py:607:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:63: in logout
pytest.driver.delete_all_cookies()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:878: in delete_all_cookies
self.execute(Command.DELETE_ALL_COOKIES)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
Failed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_past_class_button_present 386.57
self = <test_elvc_1536_864_resolution.TestElvc1536Resolution object at 0x000001EF6A895B50>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4033","high","Elvc1536Resolution","Himanshu")
def test_past_class_button_present(self,initialize_pages,testdata):

'''
Objective : To check the past class button is present

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: to check the availabe class present

'''
#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(40,testdata['lms_url'])
pytest.driver.set_window_size(1536,864)

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],40)
#STEP 3: go to the liveclasses
self.pg_liveclass.liveclasses.click_button()
#wait for page to load
time.sleep(5)

#STEP 4: to check the past class present
assert selenium_helper.is_element_present(self.pg_liveclass.locators["past_classes"][0],40) ==True
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_elvc_1536_864_resolution.py:643:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:63: in logout
pytest.driver.delete_all_cookies()
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:878: in delete_all_cookies
self.execute(Command.DELETE_ALL_COOKIES)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
Failed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_class_registration_policy_button_present 113.42
self = <test_elvc_1536_864_resolution.TestElvc1536Resolution object at 0x000001EF6A5C3190>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4033","high","Elvc1536Resolution","Himanshu")
def test_class_registration_policy_button_present(self,initialize_pages,testdata):

'''
Objective : To check the class_registration_policy button is present

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: to check the availabe class present

'''
#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(40,testdata['lms_url'])
pytest.driver.set_window_size(1536,864)

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(40,url_required[0] +testdata['course_url'])

selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],40)

#STEP 3: go to the liveclasses
self.pg_liveclass.liveclasses.click_button()

#STEP 4: to check the class registration policy present
> assert selenium_helper.is_element_present(self.pg_liveclass.locators["class_registration_policy"][0],40) ==True
E assert False == True
E +False
E -True

test\test_elvc_1536_864_resolution.py:676: AssertionError
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[aria-label='Class Registration Policy']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Failed test_focus_course.py::TestFocusCourse::test_edit_focus_course 31.38
self = <test_focus_course.TestFocusCourse object at 0x000001EF6A814E50>, initialize_pages = None
testdata = {'email': 'BQnewtest1@yopmail.com', 'home_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T1432","high","Focus course","Himanshu")
def test_edit_focus_course(self,initialize_pages,testdata):

'''
Objective : To edit the focus course and set different course as focus course

#STEP 1: navigate to lms Login url and login with existing email .
#STEP 2: click on edit focus course
#STEP 3: select course and proceed
#STEP 4: proceed to confirm to set the course as a focus course
#Step 5: Verify the course is set as the focus course

'''

#STEP 1: navigate to lms Login url and login with existing email .
lms_login_helper.login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(30,testdata['home_url'])


#STEP 2: click on edit focus course
> self.pg_home.focus_course.click_button()

test\test_focus_course.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.home_page.HomePage object at 0x000001EF6A79AB50>, loc = 'focus_course'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: focus_course

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator focus_course on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present WARNING  setup:page_factory.py:57 the locator focus_course on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present
Failed test_focus_course.py::TestFocusCourse::test_set_study_plan 47.97
self = <test_focus_course.TestFocusCourse object at 0x000001EF6A9AC340>, initialize_pages = None
testdata = {'email': 'BQnewtest1@yopmail.com', 'home_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T1432","high","Focus course","Himanshu")
def test_set_study_plan(self,initialize_pages,testdata):

'''
Objective : To make change in study hours in focus course

#STEP 1: navigate to lms Login url and login with existing email .
#STEP 2: click on study plan in focus course
#STEP 3: change the hourse and proceed
#STEP 4: Verify the study plan has changed

'''

#STEP 1: navigate to lms Login url and login with existing email .
lms_login_helper.login(testdata['email'],testdata['password'])
selenium_helper.wait_for_page_to_load(30,testdata['home_url'])

#refreshing page again
pytest.driver.refresh()
selenium_helper.wait_for_page_to_load(30,testdata['home_url'])

#STEP 2:click on study plan in focus course
> self.pg_home.study_plan.click_button()

test\test_focus_course.py:151:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.home_page.HomePage object at 0x000001EF6A80EC10>, loc = 'study_plan'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: study_plan

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator study_plan on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present WARNING  setup:page_factory.py:57 the locator study_plan on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present
Failed test_forgotpassword.py::TestForgotPassword::test_forgotpasswword_functionality 54.59
self = <test_forgotpassword.TestForgotPassword object at 0x000001EF6A7F0490>, initialize_pages = None
testdata = {'email': 'simplilearnautomation@gmail.com', 'email_details': {'email_subject': 'reset your Simplilearn password', 'pa...e': 'reset'}, 'forgetpassword_url': '/forgot-password', 'sent_msg': 'We have sent the link to reset your password at '}

@pytest.mark.test_details("SLUB-T1432","high","Forgot Password","Pavan")
def test_forgotpasswword_functionality(self,initialize_pages,testdata):

'''
Objective : To verify forgotpassword functionality .

Step1: Navigate to LMS Login url and click on forgot password link .
Step2: Verify user redirected to Forgot Password Page
Step3: Enter all the details of existing user on Forgot Password Page and click on send button .

'''

#Step1: Navigate to Login page..
pytest.driver.get(pytest.config['url'] + pytest.config['lms_login_url'])
selenium_helper.wait_for_page_to_load(30,pytest.config['url'] + pytest.config['lms_login_url'])
time.sleep(5)
> self.pg_login.lnk_forget_password.click_button()

test\test_forgotpassword.py:33:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.login_page.LoginPage object at 0x000001EF6A7D4160>, loc = 'lnk_forget_password'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: lnk_forget_password

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator lnk_forget_password on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present WARNING  setup:page_factory.py:57 the locator lnk_forget_password on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present WARNING  setup:page_factory.py:57 the locator lnk_forget_password on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present
Failed test_forgotpassword.py::TestForgotPassword::test_forgotpassword_with_invalid_user 54.71
self = <test_forgotpassword.TestForgotPassword object at 0x000001EF6A62DB50>, initialize_pages = None
testdata = {'email': 'Test', 'err_msg': 'No active account found', 'err_valid_email': 'Please enter a valid email address'}

@pytest.mark.test_details("SLUB-T1432","high","Forgot Password","Pavan")
def test_forgotpassword_with_invalid_user(self,initialize_pages,testdata):

'''
Objective : To verify forgotpassword functionality with invalid user .

Step1: Navigate to LMS Login url and click on forgot password link .
Step2: Enter all the details on Forgot Password Page and click on send button using random email
Step3: Verify error message and refresh the page
Step4: Enter all the details on Forgot Password Page and click on send button using invalid email
Step5 : Verify error message and refresh the page

'''

#Step1: Navigate to Login page..
pytest.driver.get(pytest.config['url'] + pytest.config['lms_login_url'])
selenium_helper.wait_for_page_to_load(30,pytest.config['url'] + pytest.config['lms_login_url'])
time.sleep(5)
> self.pg_login.lnk_forget_password.click_button()

test\test_forgotpassword.py:61:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.login_page.LoginPage object at 0x000001EF6A61B0D0>, loc = 'lnk_forget_password'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: lnk_forget_password

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator lnk_forget_password on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present WARNING  setup:page_factory.py:57 the locator lnk_forget_password on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present WARNING  setup:page_factory.py:57 the locator lnk_forget_password on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/profile is not present
Failed test_glvc.py::TestGlvc::test_register_for_class 50.38
self = <test_glvc.TestGlvc object at 0x000001EF6A611CD0>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T3969","high","Glvc","Himanshu")
def test_register_for_class(self,initialize_pages,testdata):

'''
Objective : To register for the class .

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses and click on available classes
STEP 4: get name of classes
STEP 5: click on registration button and confirm the registation
STEP 6: check the registration is completed

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(20,url_required[0] +testdata['course_url'])

selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],20)
#STEP 3: go to the liveclasses and click on available classes
> self.pg_liveclass.liveclasses.click_button()

test\test_glvc.py:55:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF6A739E80>, loc = 'liveclasses'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: liveclasses

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "a[title='Live Classes']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus is not present WARNING  setup:page_factory.py:57 the locator liveclasses on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus is not present
Failed test_glvc.py::TestGlvc::test_starting_soon_tag 47.08
self = <test_glvc.TestGlvc object at 0x000001EF6A7409D0>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4032","high","Glvc","Himanshu")
def test_starting_soon_tag(self,initialize_pages,testdata):

'''
Objective : To check if starting tag is present the starting date must be greater than the current date

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses and click on available classes
STEP 4: get name of details of class
STEP 5: if the class is starting soon
STEP 6: get the date and timings of classes
STEP 7: get today's day and put the date in datatime
STEP 8: check if the starting date is greater than current date

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(20,url_required[0] +testdata['course_url'])

#STEP 3: go to the liveclasses and click on available classes
selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],20)
> self.pg_liveclass.liveclasses.click_button()

test\test_glvc.py:228:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <pages.liveclasses_page.LiveClassesPage object at 0x000001EF6A9B7610>, loc = 'liveclasses'

def __getattr__(self, loc):

logging.debug(f"the current locator to be found {loc} on url {self.driver.current_url}")
if loc in self.locators.keys():
error = ""
for loc_pair in self.locators[loc]:
loc_pair[0] = self.TYPE_OF_LOCATORS[loc_pair[0].lower()]
loc_pair = tuple(loc_pair)
try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.presence_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not present")
continue

try:
element = WebDriverWait(self.driver, self.timeout).until(
EC.visibility_of_element_located(loc_pair)
)
except (StaleElementReferenceException, NoSuchElementException, TimeoutException) as e:
error = e
logging.warning(f"the locator {loc} on url {self.driver.current_url} is not visible")
#continue

element = self.get_web_element(*loc_pair)
element._locator = loc_pair
logging.debug(f"the locator {loc} is found!")
return element
> raise NoSuchElementException("An exception of type " + type(error).__name__ + " occurred. With Element -: " + loc)
E selenium.common.exceptions.NoSuchElementException: Message: An exception of type TimeoutException occurred. With Element -: liveclasses

core\page_factory.py:73: NoSuchElementException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "a[title='Live Classes']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus is not present WARNING  setup:page_factory.py:57 the locator liveclasses on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus is not present
Failed test_glvc.py::TestGlvc::test_over_tag 381.09
self = <test_glvc.TestGlvc object at 0x000001EF6A9B77C0>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T4034","high","Glvc","Himanshu")
def test_over_tag(self,initialize_pages,testdata):

'''
Objective : To check if over tag is present then end date must be less than current date

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses and click on available classes
STEP 4: get name of details of class
STEP 5: if the class is in over
STEP 6: get the date and timings of classes
STEP 7: get today's day and put the date in datatime
STEP 8: check if the end date is less then current date

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#refreshing page again
pytest.driver.refresh()
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(20,url_required[0] +testdata['course_url'])

#STEP 3: go to the liveclasses and click on available
selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],20)
self.pg_liveclass.liveclasses.click_button()
self.pg_liveclass.past_classes.click_button()
#wait for page to load
if(selenium_helper.is_element_present(self.pg_availableclass.locators["class_name"][0],20)==True):

#STEP 4: get name of details of class
CourseName=self.pg_availableclass.class_name.get_text()
status='Over'

#STEP 5: if the class is over
if(status in CourseName):

#STEP 6: get the date and timings of classes
date=self.pg_availableclass.date_time_class.get_text().split(" ")

#get the end date
EndDate=date[5].split(",")
#convert the months to integer
EndMonth=self.pg_availableclass.monthToNum(date[4])

#STEP 7: get today's day and put the date in datatime
EndingCourseDate = datetime.datetime(int(date[2]), int(EndMonth), int(EndDate[0]))
CurrentDate = datetime.datetime.now()

#STEP 8: check if the end date is less then current date
assert (CurrentDate>EndingCourseDate)
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_glvc.py:393:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:56: in logout
pg_home.logout()
pages\home_page.py:18: in logout
self.lnk_logout.execute_script(script)
core\page_factory.py:334: in execute_script
return self.parent.execute_script(script, self)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:634: in execute_script
return self.execute(command, {
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Failed test_glvc.py::TestGlvc::test_myclasses_starting_soon_tag 365.24
self = <test_glvc.TestGlvc object at 0x000001EF6A979BB0>, initialize_pages = None
testdata = {'course_url': '/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/syllabus', 'email': 'BQnewtest1@yopmail.com', 'lms_url': '/dashboard', 'password': 'Simpli@123'}

@pytest.mark.test_details("SLUB-T3973","high","Glvc","Himanshu")
def test_myclasses_starting_soon_tag(self,initialize_pages,testdata):

'''
Objective : To check if starting tag is present the starting date must be greater than the current date

STEP 1: Navigate to Login page..
STEP 2: redirected to course
STEP 3: go to the liveclasses
STEP 4: get name of details of class
STEP 5: if the class is starting soon
STEP 6: get the date and timings of classes
STEP 7: get today's day and put the date in datatime
STEP 8: check if the starting date is greater than current date

'''

#Step1: Navigate to Login page.
lms_login_helper.login(testdata['email'],testdata['password'])

#wait for lms dash board to load
selenium_helper.wait_for_page_to_load(30,testdata['lms_url'])

#STEP 2: redirected to course
url_required=pytest.driver.current_url.split("/dashboard")
pytest.driver.get(url_required[0] + testdata['course_url'])
selenium_helper.wait_for_page_to_load(20,url_required[0] +testdata['course_url'])

#STEP 3: go to the liveclasses
selenium_helper.is_element_present(self.pg_liveclass.locators["liveclasses"][0],20)
self.pg_liveclass.liveclasses.click_button()
#wait for page to load
if(selenium_helper.is_element_present(self.pg_availableclass.locators["class_name"][0],10)==True):

#STEP 4: get name of details of class
CourseName=self.pg_availableclass.class_name.get_text()
status='Starting Soon'

#STEP 5: if the class is starting soon
if(status in CourseName):

#STEP 6: get the date and timings of classes
date=self.pg_availableclass.date_time_class.get_text().split(" ")
#get the startin date
StartDate=date[1].split(",")
#convert he starting month to integer
StartMonth=self.pg_availableclass.monthToNum(date[0])

#STEP 7: get today's day and put the date in datatime
StartingCourseDate = datetime.datetime(int(date[2]), int(StartMonth), int(StartDate[0]))
CurrentDate = datetime.datetime.now()

#STEP 8: check if the starting date is greater than current date
assert (StartingCourseDate>CurrentDate)
self.pg_course.back.click_button()
> lms_login_helper.logout()

test\test_glvc.py:451:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
helper\lms_login_helper.py:56: in logout
pg_home.logout()
pages\home_page.py:18: in logout
self.lnk_logout.execute_script(script)
core\page_factory.py:334: in execute_script
return self.parent.execute_script(script, self)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:634: in execute_script
return self.execute(command, {
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 500, 'value': '{"value":{"error":"timeout","message":"timeout: Timed out receiving message from renderer: 3...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: TimeoutException
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Failed test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_PG_user_in_learning_page 68.52
self = <test_help&support.TestHelpAndSupport object at 0x000001EF6AA55FD0>, initialize_pages = None
testdata = {'dashboard_url': '/dashboard', 'email': 'hnsupportt@yopmail.com', 'liveclasses_url': 'courses/2738/Business-Analytics-with-Excel/syllabus', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T17198","Normal","Help&Support","Om")
def test_help_functionality_as_b2c_PG_user_in_learning_page(self, initialize_pages, testdata):

'''
Objective: Login to paperclip as B2C PG user, click on help from learning environment, HnS window should be displayed
Step 1: Login to paperclip as B2C PG user, click on any pg course go to program button
Step 2: Click on any course on program detail page
Step 3: Click on help from learning environment
'''

# Navigate to lms and login with valid credentials
lms_login_helper.Hns_user_login(testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on the 'Go To Program' Button
self.pg_hns_user.go_to_program_btn.click_button()
selenium_helper.wait_for_page_to_load(50, testdata['program_url'])
# Click on 'Courses' button
self.pg_hns_user.courses_btn.click_button()
selenium_helper.wait_for_page_to_load(50, testdata['liveclasses_url'])
# Click on 'Help' button
self.pg_hns_user.help_btn.click_button()
> assert selenium_helper.is_element_present(self.pg_hns_user.locators['help_search_btn'][0], 20)
E assert False
E + where False = <function is_element_present at 0x000001EF61883430>(['xpath', "//input[@id='input-11']"], 20)
E + where <function is_element_present at 0x000001EF61883430> = selenium_helper.is_element_present

test\test_help&support.py:131: AssertionError
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//input[@id='input-11']") on url http://dockerv5.simplilearn.com:8085/apachedev/git/paperclip/public/courses/2738/Business-Analytics-with-Excel/syllabus is not present
Failed test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_non_PG_user_in_profile_page 80.99
self = <selenium.webdriver.remote.switch_to.SwitchTo object at 0x000001EF67255C10>
window_name = 'CDwindow-5AF8C0210D3E79912330DB5CBAF5CDE0'

def _w3c_window(self, window_name):
def send_handle(h):
self._driver.execute(Command.SWITCH_TO_WINDOW, {'handle': h})

try:
# Try using it as a handle first.
> send_handle(window_name)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\switch_to.py:123:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

h = 'CDwindow-5AF8C0210D3E79912330DB5CBAF5CDE0'

def send_handle(h):
> self._driver.execute(Command.SWITCH_TO_WINDOW, {'handle': h})

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\switch_to.py:119:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.chrome.webdriver.WebDriver (session="9b3a21781391fdbf94e369f7b18da6d3")>
driver_command = 'switchToWindow', params = {'handle': 'CDwindow-5AF8C0210D3E79912330DB5CBAF5CDE0'}

def execute(self, driver_command, params=None):
"""
Sends a command to be executed by a command.CommandExecutor.

:Args:
- driver_command: The name of the command to execute as a string.
- params: A dictionary of named parameters to send with the command.

:Returns:
The command's JSON response loaded into a dictionary object.
"""
if self.session_id is not None:
if not params:
params = {'sessionId': self.session_id}
elif 'sessionId' not in params:
params['sessionId'] = self.session_id

params = self._wrap_value(params)
response = self.command_executor.execute(driver_command, params)
if response:
> self.error_handler.check_response(response)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window\\n (Session info: headless chr...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException

During handling of the above exception, another exception occurred:

self = <test_help&support.TestHelpAndSupport object at 0x000001EF6A948250>, initialize_pages = None
testdata = {'courses_url': '/program/post-graduates', 'dashboard_url': '/dashboard', 'email': 'atlascpmdemo1@yopmail.com', 'password': 'Simpli@123', ...}

@pytest.mark.test_details("SLUB-T17199","Normal","Help&Support","Om")
def test_help_functionality_as_b2c_non_PG_user_in_profile_page(self, initialize_pages, testdata):

'''
Objective: Login to paperclip as B2C non-PG user, click on profile
Step 1: Login to paperclip as B2C non-PG user, click on profile
Step 2: Click on Help from profile page
'''

# Navigate to lms and login with valid credentials
lms_login_helper.Hns_user_login(testdata['email'], testdata['password'])
selenium_helper.wait_for_page_to_load(50, testdata['dashboard_url'])
# Click on 'Profile' Dropdown
self.pg_hns_user.profile_dropdown_btn.click_button()
time.sleep(3)
default_handle = pytest.driver.current_window_handle
# Click on 'profile' button
self.pg_hns_user.profile_btn.click_button()
handles = list(pytest.driver.window_handles)
if len(handles) > 1:
pytest.driver.switch_to.window(handles[1])
selenium_helper.wait_for_page_to_load(50, testdata['profile_url'])
# Click on "Help" button
self.pg_hns_user.profile_help_btn.click_button()
assert selenium_helper.is_element_present(self.pg_hns_user.locators['help_search_btn'][0], 30)
pytest.driver.close()
> pytest.driver.switch_to.window(default_handle)

test\test_help&support.py:162:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\switch_to.py:112: in window
self._w3c_window(window_name)
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\switch_to.py:126: in _w3c_window
original_handle = self._driver.current_window_handle
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:711: in current_window_handle
return self.execute(Command.W3C_GET_CURRENT_WINDOW_HANDLE)['value']
c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\webdriver.py:321: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x000001EF67255100>
response = {'status': 404, 'value': '{"value":{"error":"no such window","message":"no such window: target window already closed\\...\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A7E+286]\\n\\tRtlGetAppContainerNamedObjectPath [0x776E7A4E+238]\\n"}}'}

def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.

:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.

:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
if len(value.keys()) == 1:
value = value['value']
status = value.get('error', None)
if status is None:
status = value["status"]
message = value["value"]
if not isinstance(message, basestring):
value = message
message = message.get('message')
else:
message = value.get('message', None)
except ValueError:
pass

exception_class = ErrorInResponseException
if status in ErrorCode.NO_SUCH_ELEMENT:
exception_class = NoSuchElementException
elif status in ErrorCode.NO_SUCH_FRAME:
exception_class = NoSuchFrameException
elif status in ErrorCode.NO_SUCH_WINDOW:
exception_class = NoSuchWindowException
elif status in ErrorCode.STALE_ELEMENT_REFERENCE:
exception_class = StaleElementReferenceException
elif status in ErrorCode.ELEMENT_NOT_VISIBLE:
exception_class = ElementNotVisibleException
elif status in ErrorCode.INVALID_ELEMENT_STATE:
exception_class = InvalidElementStateException
elif status in ErrorCode.INVALID_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR \
or status in ErrorCode.INVALID_XPATH_SELECTOR_RETURN_TYPER:
exception_class = InvalidSelectorException
elif status in ErrorCode.ELEMENT_IS_NOT_SELECTABLE:
exception_class = ElementNotSelectableException
elif status in ErrorCode.ELEMENT_NOT_INTERACTABLE:
exception_class = ElementNotInteractableException
elif status in ErrorCode.INVALID_COOKIE_DOMAIN:
exception_class = InvalidCookieDomainException
elif status in ErrorCode.UNABLE_TO_SET_COOKIE:
exception_class = UnableToSetCookieException
elif status in ErrorCode.TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.SCRIPT_TIMEOUT:
exception_class = TimeoutException
elif status in ErrorCode.UNKNOWN_ERROR:
exception_class = WebDriverException
elif status in ErrorCode.UNEXPECTED_ALERT_OPEN:
exception_class = UnexpectedAlertPresentException
elif status in ErrorCode.NO_ALERT_OPEN:
exception_class = NoAlertPresentException
elif status in ErrorCode.IME_NOT_AVAILABLE:
exception_class = ImeNotAvailableException
elif status in ErrorCode.IME_ENGINE_ACTIVATION_FAILED:
exception_class = ImeActivationFailedException
elif status in ErrorCode.MOVE_TARGET_OUT_OF_BOUNDS:
exception_class = MoveTargetOutOfBoundsException
elif status in ErrorCode.JAVASCRIPT_ERROR:
exception_class = JavascriptException
elif status in ErrorCode.SESSION_NOT_CREATED:
exception_class = SessionNotCreatedException
elif status in ErrorCode.INVALID_ARGUMENT:
exception_class = InvalidArgumentException
elif status in ErrorCode.NO_SUCH_COOKIE:
exception_class = NoSuchCookieException
elif status in ErrorCode.UNABLE_TO_CAPTURE_SCREEN:
exception_class = ScreenshotException
elif status in ErrorCode.ELEMENT_CLICK_INTERCEPTED:
exception_class = ElementClickInterceptedException
elif status in ErrorCode.INSECURE_CERTIFICATE:
exception_class = InsecureCertificateException
elif status in ErrorCode.INVALID_COORDINATES:
exception_class = InvalidCoordinatesException
elif status in ErrorCode.INVALID_SESSION_ID:
exception_class = InvalidSessionIdException
elif status in ErrorCode.UNKNOWN_METHOD:
exception_class = UnknownMethodException
else:
exception_class = WebDriverException
if value == '' or value is None:
value = response['value']
if isinstance(value, basestring):
if exception_class == ErrorInResponseException:
raise exception_class(response, value)
raise exception_class(value)
if message == "" and 'message' in value:
message = value['message']

screen = None
if 'screen' in value:
screen = value['screen']

stacktrace = None
if 'stackTrace' in value and value['stackTrace']:
stacktrace = []
try:
for frame in value['stackTrace']:
line = self._value_or_default(frame, 'lineNumber', '')
file = self._value_or_default(frame, 'fileName', '<anonymous>')
if line:
file = "%s:%s" % (file, line)
meth = self._value_or_default(frame, 'methodName', '<anonymous>')
if 'className' in frame:
meth = "%s.%s" % (frame['className'], meth)
msg = " at %s (%s)"
msg = msg % (meth, file)
stacktrace.append(msg)
except TypeError:
pass
if exception_class == ErrorInResponseException:
raise exception_class(response, message)
elif exception_class == UnexpectedAlertPresentException:
alert_text = None
if 'data' in value:
alert_text = value['data'].get('text')
elif 'alert' in value:
alert_text = value['alert'].get('text')
raise exception_class(message, screen, stacktrace, alert_text)
> raise exception_class(message, screen, stacktrace)
E selenium.common.exceptions.NoSuchWindowException: Message: no such window: target window already closed
E from unknown error: web view not found
E (Session info: headless chrome=101.0.4951.54)

c:\users\qateam\appdata\local\programs\python\python38\lib\site-packages\selenium\webdriver\remote\errorhandler.py:242: NoSuchWindowException
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_NewUserRegisteration_StandAloneRegisteration_B2C 121.30
-------------------------------Captured log setup-------------------------------
INFO  setup:conftest.py:132 reading config from path "config.json" INFO  setup:conftest.py:107 creating driver for provided browser - chrome
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:150 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:151 The leaner registered is : irisregression8438@yopmail.com
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_ProgramAssignmentVerififcation 87.98
-------------------------------Captured log call--------------------------------
INFO  setup:simplex_login_helper.py:12 loggedin to simplex with admin@simplilearn.com INFO  setup:simplex_page.py:32 clicked on listing INFO  setup:simplex_page.py:35 clicked on Bundles INFO  setup:simplex_page.py:43 bundle 163 found INFO  setup:simplex_page.py:80 Course 1  Machine Learning-687 INFO  setup:simplex_page.py:80 Course 2  2D Video Game Character Animation for Beginners-459 (optional) INFO  setup:simplex_page.py:80 Course 3  Agile Scrum Foundation-1 INFO  setup:simplex_page.py:80 Course 4  Phase-1: Implement OOPS using JAVA with Data Structures and Beyond-1431 (optional) INFO  setup:simplex_page.py:80 Course 5  Phase 1 - Agile, Git, and Basics of C# Programming-1531 (optional) INFO  setup:simplex_page.py:80 Course 6  Phase-2: Become a back-end expert-1449 (optional) INFO  setup:simplex_page.py:80 Course 7  Phase-3: Implement Frameworks the DevOps way-1450 INFO  setup:simplex_page.py:80 Course 8  Phase 4 - .NET Application Testing and Deployment-1534 INFO  setup:simplex_page.py:80 Course 9  Administering MS SQL server 2012 Databases-206 INFO  setup:simplex_page.py:96 Course 1  Power BI-922 INFO  setup:simplex_page.py:112 Course 1  Agile Scrum Master-659 INFO  setup:test_LMS_Regression_Test.py:187 total 9 courses in mandatory courses for MP INFO  setup:simplex_page.py:32 clicked on listing INFO  setup:simplex_page.py:35 clicked on Bundles INFO  setup:simplex_page.py:43 bundle 156 found INFO  setup:simplex_page.py:129 Course 1  .NET FSD Capstone Project-1736 INFO  setup:simplex_page.py:129 Course 2  Accelerated Deep Learning with GPU-1360 INFO  setup:simplex_page.py:129 Course 3  Achieving High Engagement-1839 INFO  setup:simplex_page.py:129 Course 4  "Categories we play in (Substantial Product Acitvity) - CD/GTA"-1967 INFO  setup:simplex_page.py:145 Course 1  .NET Programming-906 INFO  setup:simplex_page.py:145 Course 2  Data Science with Python-684 INFO  setup:simplex_page.py:161 No Prerequisite Course Added INFO  setup:test_LMS_Regression_Test.py:203 total 4 courses in mandatory courses for PGP INFO  setup:simplex_page.py:26 admin logged out from Simplex INFO  setup:simplex_login_helper.py:17 logout from simplex with successfull
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMSAdmin_PGPAssignment_WithoutCohort 272.73
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:239 test data Loaded INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:231 clicked on submit button on assignment page INFO  setup:assignment_page.py:235 learner registered sucessfully INFO  setup:assignment_page.py:236 Program assigned successfully INFO  setup:test_LMS_Regression_Test.py:258 Admin Logged Out INFO  setup:test_LMS_Regression_Test.py:264 cookies Cleared INFO  setup:test_LMS_Regression_Test.py:275 popup notification appeared gor new learner ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:30 clicked on PG Program Tab INFO  setup:lms_page.py:31 Assigned PG Program Is Post Graduate Program in Data Science INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 .NET FSD Capstone Project : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:290 course is not matching with simplex for course : .NET FSD Capstone Project INFO  setup:test_LMS_Regression_Test.py:297 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_CohortCreation 361.41
-------------------------------Captured log call--------------------------------
INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 mp INFO  setup:cohorts_page.py:47 MP Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:70 course name set to Full Stack Java Developer - 163 INFO  setup:cohorts_page.py:74 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression'] INFO  setup:cohorts_page.py:170 MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression cohort is present INFO  setup:cohorts_page.py:172 cohort name match INFO  setup:cohorts_page.py:180 clicked on classes tab INFO  setup:cohorts_page.py:184 clicked on New-live-classes button INFO  setup:cohorts_page.py:193 stage 4 started INFO  setup:cohorts_page.py:218 clicked on next button INFO  setup:cohorts_page.py:219 stage 5 started INFO  setup:cohorts_page.py:224 Test data for automation - added to class name INFO  setup:cohorts_page.py:227 clicked on next button after adding text INFO  setup:cohorts_page.py:233 class created with class name # Machine Learning JUNE 2022 batch 2Test data for CCR automation # INFO  setup:cohorts_page.py:234 stage 6 started INFO  setup:test_LMS_Regression_Test.py:331 1st cohort created INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 pgp INFO  setup:cohorts_page.py:53 UNIVERSITY Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:106 course name set to Post Graduate Program in Data Science - 156 INFO  setup:cohorts_page.py:110 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression'] INFO  setup:cohorts_page.py:316 PGP Data Science Jun 2022 cohort 465test data for LMS Regression cohort is present INFO  setup:cohorts_page.py:318 cohort name match INFO  setup:cohorts_page.py:324 clicked on classes tab INFO  setup:cohorts_page.py:327 clicked on New-live-classes button INFO  setup:cohorts_page.py:335 stage 4 started INFO  setup:cohorts_page.py:357 clicked on next button INFO  setup:cohorts_page.py:358 stage 5 started INFO  setup:cohorts_page.py:362 Test data for automation - added to class name INFO  setup:cohorts_page.py:365 clicked on next button after adding text INFO  setup:cohorts_page.py:372 class created with class name # .NET FSD Casptone Project JUNE 2022 batch 2Test data for CCR automation # INFO  setup:cohorts_page.py:373 stage 6 started INFO  setup:test_LMS_Regression_Test.py:351 2nd cohort created
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMSAdmin_MPAssignment_classicMasters 659.19
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:375 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:376 The leaner registered is : irisregression7420@yopmail.com INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:278 clicked on submit button on assignment page ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//h5[contains(text(),'successfully')]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/admin/support/assign is not present INFO  setup:test_LMS_Regression_Test.py:396 Admin Logged Out INFO  setup:simplex_login_helper.py:12 loggedin to simplex with admin@simplilearn.com INFO  setup:simplex_page.py:32 clicked on listing INFO  setup:simplex_page.py:35 clicked on Bundles INFO  setup:simplex_page.py:54 bundle 67 found INFO  setup:simplex_page.py:67 all courses captured in classic master program INFO  setup:test_LMS_Regression_Test.py:411 ['Remove All\nX', 'Big Data Hadoop and Spark Developer - 15\nX', 'Lean Management - 88\nX', 'Core Java Certification Training - 860\nX'] INFO  setup:simplex_page.py:26 admin logged out from Simplex INFO  setup:simplex_login_helper.py:17 logout from simplex with successfull INFO  setup:test_LMS_Regression_Test.py:418 cookies Cleared INFO  setup:test_LMS_Regression_Test.py:437 popup notification appeared gor new learner ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 Big Data Hadoop and Spark Developer : course present in courses tab INFO  setup:lms_page.py:50 Lean Management : course present in courses tab INFO  setup:lms_page.py:50 Core Java : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:452 Assertion Succes for Big Data Hadoop and Spark Developer INFO  setup:test_LMS_Regression_Test.py:452 Assertion Succes for Lean Management INFO  setup:test_LMS_Regression_Test.py:452 Assertion Succes for Core Java INFO  setup:test_LMS_Regression_Test.py:456 all courses available under courses tab as per Simplex INFO  setup:test_LMS_Regression_Test.py:463 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMSAdmin_MPAssignment_CohortMaster 624.01
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:489 test data Loaded INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:494 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:495 The leaner registered is : irisregression4047@yopmail.com INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:40 clicked on submit button on assignment page INFO  setup:assignment_page.py:43 learner registered sucessfully INFO  setup:assignment_page.py:44 Program assigned successfully INFO  setup:test_LMS_Regression_Test.py:515 Admin Logged Out INFO  setup:test_LMS_Regression_Test.py:519 cookies Cleared INFO  setup:test_LMS_Regression_Test.py:538 popup notification appeared gor new learner ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Full Stack Java Developer INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 Machine Learning V2 : course present in courses tab INFO  setup:lms_page.py:50 2D Video Game Character Animation for Beginners : course present in courses tab INFO  setup:lms_page.py:50 Agile Scrum Foundation : course present in courses tab INFO  setup:lms_page.py:50 Implement OOPS using JAVA with Data Structures and Beyond : course present in courses tab INFO  setup:lms_page.py:50 E356 : course present in courses tab INFO  setup:lms_page.py:50 Phase-2: Become a back-end expert : course present in courses tab INFO  setup:lms_page.py:50 Phase-3: Implement Frameworks the DevOps way : course present in courses tab INFO  setup:lms_page.py:50 elearning test : course present in courses tab INFO  setup:lms_page.py:50 Administering Microsoft SQL Server 2012 Databases (Exam 70-462) : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:554 all courses available under courses tab as per Simplex INFO  setup:test_LMS_Regression_Test.py:562 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMSAdmin_PGPAssignment_Cohortprogram 379.60
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:588 test data Loaded INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:593 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:594 The leaner registered is : irisregression1929@yopmail.com INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:324 clicked on submit button on assignment page INFO  setup:assignment_page.py:327 learner registered sucessfully INFO  setup:test_LMS_Regression_Test.py:614 Admin Logged Out INFO  setup:test_LMS_Regression_Test.py:618 cookies Cleared INFO  setup:test_LMS_Regression_Test.py:637 community popup notification appeared gor new learner ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:30 clicked on PG Program Tab INFO  setup:lms_page.py:31 Assigned PG Program Is Post Graduate Program in Data Science INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 .NET FSD Capstone Project : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:652 .NET FSD Capstone Project course available under courses tab as per Simplex INFO  setup:test_LMS_Regression_Test.py:654 .NET FSD Capstone Project is not matching with Simplex INFO  setup:test_LMS_Regression_Test.py:654 .NET FSD Capstone Project is not matching with Simplex INFO  setup:test_LMS_Regression_Test.py:654 .NET FSD Capstone Project is not matching with Simplex INFO  setup:test_LMS_Regression_Test.py:661 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyPGProgram 197.69
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:684 test data Loaded INFO  setup:test_LMS_Regression_Test.py:692 unser landed on Onboarding Page ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:64 Cohort on Program Tile : PGP Data Science Jun 2022 cohort 465test data for LMS Regression INFO  setup:test_LMS_Regression_Test.py:706 cohort appeared in program tile : PGP Data Science Jun 2022 cohort 465test data for LMS Regression INFO  setup:db_helper.py:24 DB_type selected : mysql INFO  setup:db_connection.py:98 Mysql Connection is Established INFO  setup:db_connection.py:108 Requested Query : Select cohort_name from engageX_test.learner_program as lp join engageX_test.cohort as ch on lp.active_cohort_id = ch.id where lp.user_id = (Select distinct uid from apollo_cloud6_main.users where mail = 'irisregression1929@yopmail.com') and lp.program_id = 156; INFO  setup:db_connection.py:105 Mysql Connection is closed INFO  setup:test_LMS_Regression_Test.py:714 Cohort Matched With DB amd Program Tile Success INFO  setup:lms_page.py:30 clicked on PG Program Tab INFO  setup:lms_page.py:31 Assigned PG Program Is Post Graduate Program in Data Science INFO  setup:lms_page.py:70 Course Count on Program Tile : 1 WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 .NET FSD Capstone Project : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:732 Total Courses in Courses tab : 1 INFO  setup:test_LMS_Regression_Test.py:734 course Count Match INFO  setup:test_LMS_Regression_Test.py:743 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyMPProgram_CohortMaster 199.39
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:765 test data Loaded INFO  setup:test_LMS_Regression_Test.py:773 unser landed on Onboarding Page ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:64 Cohort on Program Tile : MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression INFO  setup:test_LMS_Regression_Test.py:787 cohort appeared in program tile : MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression INFO  setup:db_helper.py:24 DB_type selected : mysql INFO  setup:db_connection.py:98 Mysql Connection is Established INFO  setup:db_connection.py:108 Requested Query : Select cohort_name from engageX_test.learner_program as lp join engageX_test.cohort as ch on lp.active_cohort_id = ch.id where lp.user_id = (Select distinct uid from apollo_cloud6_main.users where mail = 'irisregression4047@yopmail.com') and lp.program_id = 163; INFO  setup:db_connection.py:105 Mysql Connection is closed INFO  setup:test_LMS_Regression_Test.py:795 Cohort Matched With DB amd Program Tile Success INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Full Stack Java Developer INFO  setup:lms_page.py:70 Course Count on Program Tile : 5 WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 Machine Learning V2 : course present in courses tab INFO  setup:lms_page.py:50 2D Video Game Character Animation for Beginners : course present in courses tab INFO  setup:lms_page.py:50 Agile Scrum Foundation : course present in courses tab INFO  setup:lms_page.py:50 Implement OOPS using JAVA with Data Structures and Beyond : course present in courses tab INFO  setup:lms_page.py:50 E356 : course present in courses tab INFO  setup:lms_page.py:50 Phase-2: Become a back-end expert : course present in courses tab INFO  setup:lms_page.py:50 Phase-3: Implement Frameworks the DevOps way : course present in courses tab INFO  setup:lms_page.py:50 elearning test : course present in courses tab INFO  setup:lms_page.py:50 Administering Microsoft SQL Server 2012 Databases (Exam 70-462) : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:813 Total Courses in Courses tab : 9 INFO  setup:test_LMS_Regression_Test.py:817 course Count doesnot match INFO  setup:test_LMS_Regression_Test.py:824 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyMPProgram_ClassicMaster 196.70
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:845 test data Loaded INFO  setup:test_LMS_Regression_Test.py:853 unser landed on Onboarding Page ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:db_helper.py:24 DB_type selected : mysql INFO  setup:db_connection.py:98 Mysql Connection is Established INFO  setup:db_connection.py:108 Requested Query : Select * from engageX_test.learner_program where program_id = 67 and user_id = (Select distinct uid from apollo_cloud6_main.users where mail = 'irisregression7420@yopmail.com') INFO  setup:db_connection.py:105 Mysql Connection is closed INFO  setup:test_LMS_Regression_Test.py:869 program Id : [67] INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz INFO  setup:lms_page.py:70 Course Count on Program Tile : 3 WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:44 inside Courses tab INFO  setup:lms_page.py:50 Big Data Hadoop and Spark Developer : course present in courses tab INFO  setup:lms_page.py:50 Lean Management : course present in courses tab INFO  setup:lms_page.py:50 Core Java : course present in courses tab INFO  setup:test_LMS_Regression_Test.py:885 Total Courses in Courses tab : 3 INFO  setup:test_LMS_Regression_Test.py:887 course Count Match INFO  setup:test_LMS_Regression_Test.py:896 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMSVerify_CorestackLab 196.61
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1027 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present INFO  setup:lms_page.py:154 Labs Label Available INFO  setup:lms_page.py:155 licked on Practice LAB INFO  setup:lms_page.py:161 clicked in Corestack lab INFO  setup:lms_page.py:165 clicked on Launch Lab ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@title='Launch Lab']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/practice-labs is not present INFO  setup:lms_page.py:177 clicked on LAUNCH LAB INFO  setup:lms_page.py:219 clicked on Terminate INFO  setup:lms_page.py:222 clicked on Accept on Pop-up window INFO  setup:lms_page.py:227 clicked on BAck Button INFO  setup:test_LMS_Regression_Test.py:1066 Lab Ended : Corestack INFO  setup:test_LMS_Regression_Test.py:1074 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMSVerify_VocareumLab 191.98
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1097 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present INFO  setup:lms_page.py:154 Labs Label Available INFO  setup:lms_page.py:155 licked on Practice LAB INFO  setup:lms_page.py:200 clicked in Vocareum lab INFO  setup:lms_page.py:204 clicked on Launch Lab ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@title='Launch Lab']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/practice-labs is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//div[@id='endclabsbtn']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/practice-labs is not present INFO  setup:test_LMS_Regression_Test.py:1137 Lab Ended : Vocareum INFO  setup:test_LMS_Regression_Test.py:1141 clicked on BAck Button INFO  setup:test_LMS_Regression_Test.py:1146 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyAsessment_AssessmentSubmission_Fail 190.72
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1171 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present INFO  setup:assessment_page.py:72 clicked on btn TAKE IT NOW INFO  setup:selenium_helper.py:67 Not able to add the course as : Are you sure you want to start ? INFO  setup:selenium_helper.py:69 Alert Accepted INFO  setup:assessment_page.py:75 Allert Accepted ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[contains(text(),'start new attempt')]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/assessment is not present INFO  setup:assessment_page.py:86 Total no of test appeared is : 75 INFO  setup:assessment_page.py:93 Right hand side bar available with option : All INFO  setup:assessment_page.py:93 Right hand side bar available with option : ANSWERED INFO  setup:assessment_page.py:93 Right hand side bar available with option : SKIPPED INFO  setup:assessment_page.py:108 clicked on Submit button INFO  setup:assessment_page.py:144 clicked on Finish Assessment INFO  setup:assessment_page.py:147 clicked on Yes on pop-up window INFO  setup:assessment_page.py:159 Failed Status Appeared INFO  setup:assessment_page.py:170 1/3 Attempts INFO  setup:test_LMS_Regression_Test.py:1225 clicked on BAck Button INFO  setup:test_LMS_Regression_Test.py:1231 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyAsessment_AssessmentSubmission_Pass 772.71
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1257 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/syllabus is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//div[@class='data']//p)[1]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/assessment is not present INFO  setup:assessment_page.py:189 clicked on btn TAKE IT NOW INFO  setup:selenium_helper.py:67 Not able to add the course as : Are you sure you want to start ? INFO  setup:selenium_helper.py:69 Alert Accepted INFO  setup:assessment_page.py:192 Allert Accepted ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[contains(text(),'start new attempt')]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/assessment is not present INFO  setup:assessment_page.py:202 Total no of test appeared is : 40 INFO  setup:assessment_page.py:93 Right hand side bar available with option : All INFO  setup:assessment_page.py:93 Right hand side bar available with option : ANSWERED INFO  setup:assessment_page.py:93 Right hand side bar available with option : SKIPPED INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 1 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 2 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 3 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 4 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 5 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 6 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 7 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 8 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 9 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 10 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 11 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 12 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 13 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 14 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 15 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 16 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 17 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 18 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 19 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 20 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 21 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 22 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 23 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 24 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 25 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 26 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 27 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 28 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 29 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 30 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 31 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 32 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 33 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 34 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 35 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 36 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 37 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 38 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 39 INFO  setup:assessment_page.py:130 Clicked on Submit button for Question no : 40 ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[contains(text(),'Wait')]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer/assessment is not present INFO  setup:assessment_page.py:215 Passed Status Appeared INFO  setup:assessment_page.py:170 1/3 Attempts INFO  setup:test_LMS_Regression_Test.py:1310 clicked on BAck Button INFO  setup:test_LMS_Regression_Test.py:1316 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_LMS_VerifyOSLCourseUnlock 166.44
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1822 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:test_LMS_Regression_Test.py:1849 Certification tab is present INFO  setup:certificate_page.py:273 Big Data Hadoop and Spark Developer : Certificate Status : CLAIM CERTIFICATE INFO  setup:certificate_page.py:273 Lean Management : Certificate Status : VIEW COURSE INFO  setup:certificate_page.py:273 Core Java : Certificate Status : VIEW COURSE INFO  setup:test_LMS_Regression_Test.py:1864 All mandatory Courses are not Completed INFO  setup:test_LMS_Regression_Test.py:1865 Can't Download Certificate INFO  setup:test_LMS_Regression_Test.py:1868 logging out Learner INFO  setup:test_LMS_Regression_Test.py:1872 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_LMS_Dashboard_LearnerWithCertificationTab_VerfiyLabels 693.90
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:1987 test data Loaded INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:527 clicked on submit button on assignment page ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//h5[contains(text(),'successfully')]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/admin/support/assign is not present INFO  setup:assignment_page.py:530 learner registered sucessfully INFO  setup:test_LMS_Regression_Test.py:2008 Admin Logged Out ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:362 ON Header BAR INFO  setup:lms_page.py:367 On Header Bar : My Courses INFO  setup:lms_page.py:367 On Header Bar : My Resources INFO  setup:lms_page.py:367 On Header Bar : Community INFO  setup:lms_page.py:367 On Header Bar : Profile INFO  setup:lms_page.py:367 On Header Bar : User Profile INFO  setup:lms_page.py:367 On Header Bar : Certificates INFO  setup:lms_page.py:367 On Header Bar : Subscriptions INFO  setup:lms_page.py:367 On Header Bar : DigitaKey INFO  setup:lms_page.py:367 On Header Bar : Exam INFO  setup:lms_page.py:367 On Header Bar : Invoices INFO  setup:lms_page.py:367 On Header Bar : Support requests INFO  setup:lms_page.py:367 On Header Bar : Logout INFO  setup:lms_page.py:372 On Program Tab INFO  setup:lms_page.py:377 On Program Tab : Master's Programs INFO  setup:lms_page.py:377 On Program Tab : Certification Programs INFO  setup:lms_page.py:379 On Courses Card INFO  setup:lms_page.py:385 On Program Card : Sort By INFO  setup:lms_page.py:385 On Program Card : Progress INFO  setup:lms_page.py:385 On Program Card : Recent INFO  setup:lms_page.py:385 On Program Card : A-Z INFO  setup:lms_page.py:385 On Program Card : Z-A INFO  setup:lms_page.py:394 On Program Card : Search Course INFO  setup:lms_page.py:401 On Program Card : Dropdown Button INFO  setup:lms_page.py:410 On Program Card : Big Data Hadoop and Spark Developer INFO  setup:lms_page.py:417 On Program Card : Know More ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//div[@class='upskills_container'])//a[@aria-label]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:427 On Reffer Card INFO  setup:lms_page.py:432 On Reffer Card : Invite a friend INFO  setup:test_LMS_Regression_Test.py:2039 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2043 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_LMS_Dashboard_LearnerWithMasters_ProgramTab_VerfiyLabels 86.42
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2060 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz INFO  setup:lms_page.py:289 ON Header BAR INFO  setup:lms_page.py:294 On Header Bar : My Courses INFO  setup:lms_page.py:294 On Header Bar : My Resources INFO  setup:lms_page.py:294 On Header Bar : Community INFO  setup:lms_page.py:294 On Header Bar : Profile INFO  setup:lms_page.py:294 On Header Bar : User Profile INFO  setup:lms_page.py:294 On Header Bar : Certificates INFO  setup:lms_page.py:294 On Header Bar : Subscriptions INFO  setup:lms_page.py:294 On Header Bar : DigitaKey INFO  setup:lms_page.py:294 On Header Bar : Exam INFO  setup:lms_page.py:294 On Header Bar : Invoices INFO  setup:lms_page.py:294 On Header Bar : Support requests INFO  setup:lms_page.py:294 On Header Bar : Logout INFO  setup:lms_page.py:298 On Program Tab INFO  setup:lms_page.py:303 On Program Tab : Master's Programs INFO  setup:lms_page.py:305 On Program Card INFO  setup:lms_page.py:311 On Program Card : Know More INFO  setup:lms_page.py:317 On Program Card : GO TO PROGRAM INFO  setup:lms_page.py:320 On Reffer Card INFO  setup:lms_page.py:325 On Reffer Card : Invite a friend INFO  setup:test_LMS_Regression_Test.py:2084 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2088 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_LMS_Dashboard_LearnerWithSkillUpTab_VerfiyLabels 84.82
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2104 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:362 ON Header BAR INFO  setup:lms_page.py:367 On Header Bar : My Courses INFO  setup:lms_page.py:367 On Header Bar : My Resources INFO  setup:lms_page.py:367 On Header Bar : Community INFO  setup:lms_page.py:367 On Header Bar : Profile INFO  setup:lms_page.py:367 On Header Bar : User Profile INFO  setup:lms_page.py:367 On Header Bar : Certificates INFO  setup:lms_page.py:367 On Header Bar : Subscriptions INFO  setup:lms_page.py:367 On Header Bar : DigitaKey INFO  setup:lms_page.py:367 On Header Bar : Exam INFO  setup:lms_page.py:367 On Header Bar : Invoices INFO  setup:lms_page.py:367 On Header Bar : Support requests INFO  setup:lms_page.py:367 On Header Bar : Logout INFO  setup:lms_page.py:372 On Program Tab INFO  setup:lms_page.py:377 On Program Tab : Master's Programs INFO  setup:lms_page.py:377 On Program Tab : Certification Programs INFO  setup:lms_page.py:377 On Program Tab : SkillUp INFO  setup:lms_page.py:379 On Courses Card INFO  setup:lms_page.py:385 On Program Card : Sort By INFO  setup:lms_page.py:385 On Program Card : Progress INFO  setup:lms_page.py:385 On Program Card : Recent INFO  setup:lms_page.py:385 On Program Card : A-Z INFO  setup:lms_page.py:385 On Program Card : Z-A INFO  setup:lms_page.py:394 On Program Card : Search Course INFO  setup:lms_page.py:401 On Program Card : Dropdown Button INFO  setup:lms_page.py:410 On Program Card : Agile Scrum Foundation INFO  setup:lms_page.py:417 On Program Card : Know More INFO  setup:lms_page.py:417 On Program Card : share freemium course INFO  setup:lms_page.py:424 On Program Card : download android app INFO  setup:lms_page.py:424 On Program Card : download ios applink INFO  setup:lms_page.py:427 On Reffer Card INFO  setup:lms_page.py:432 On Reffer Card : download android app INFO  setup:lms_page.py:432 On Reffer Card : download ios applink INFO  setup:test_LMS_Regression_Test.py:2127 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2131 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_ProgramDetailsPage_LearnerWithProgramDetailsCoursesTab_VerfiyLabels 99.68
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2149 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz INFO  setup:lms_page.py:329 ON Header BAR INFO  setup:lms_page.py:334 On Header Bar : My Courses INFO  setup:lms_page.py:334 On Header Bar : My Resources INFO  setup:lms_page.py:334 On Header Bar : Community INFO  setup:lms_page.py:334 On Header Bar : Profile INFO  setup:lms_page.py:334 On Header Bar : User Profile INFO  setup:lms_page.py:334 On Header Bar : Certificates INFO  setup:lms_page.py:334 On Header Bar : Subscriptions INFO  setup:lms_page.py:334 On Header Bar : DigitaKey INFO  setup:lms_page.py:334 On Header Bar : Exam INFO  setup:lms_page.py:334 On Header Bar : Invoices INFO  setup:lms_page.py:334 On Header Bar : Support requests INFO  setup:lms_page.py:334 On Header Bar : Logout INFO  setup:lms_page.py:339 On Program Tab INFO  setup:lms_page.py:344 On Program Tab : Courses INFO  setup:lms_page.py:344 On Program Tab : electives INFO  setup:lms_page.py:344 On Program Tab : Certification INFO  setup:lms_page.py:346 On Courses Card INFO  setup:lms_page.py:351 On Program Card : Big Data Hadoop and Spark Developer INFO  setup:lms_page.py:351 On Program Card : Lean Management INFO  setup:lms_page.py:351 On Program Card : Core Java INFO  setup:lms_page.py:356 On Program Card : Dropdown Button INFO  setup:lms_page.py:356 On Program Card : View Learning Logs INFO  setup:lms_page.py:356 On Program Card : Dropdown Button INFO  setup:lms_page.py:356 On Program Card : View Learning Logs INFO  setup:lms_page.py:356 On Program Card : Dropdown Button INFO  setup:lms_page.py:356 On Program Card : View Learning Logs INFO  setup:test_LMS_Regression_Test.py:2191 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2195 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_LMS_Dashboard_LearnerWithMasters_ProgramTab_VerfiyTabNavigation 105.31
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2212 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz INFO  setup:lms_page.py:618 current Web element Title is : GO TO PROGRAM INFO  setup:lms_page.py:622 current Web element Title is : Invite a friend INFO  setup:lms_page.py:622 current Web element Title is : Share on Twitter INFO  setup:lms_page.py:622 current Web element Title is : About Us INFO  setup:lms_page.py:622 current Web element Title is : Blog as Guest INFO  setup:lms_page.py:622 current Web element Title is : Authorised Training Partner INFO  setup:lms_page.py:622 current Web element Title is : Free Trial Policy INFO  setup:lms_page.py:622 current Web element Title is : Community INFO  setup:lms_page.py:622 current Web element Title is : Share on Facebook INFO  setup:lms_page.py:622 current Web element Title is : Refund Policy INFO  setup:lms_page.py:622 current Web element Title is : Help INFO  setup:lms_page.py:622 current Web element Title is : In the Media INFO  setup:lms_page.py:622 current Web element Title is : Privacy Policy INFO  setup:lms_page.py:622 current Web element Title is : Master's Programs INFO  setup:lms_page.py:622 current Web element Title is : Become an Affiliate INFO  setup:lms_page.py:622 current Web element Title is : Study Central INFO  setup:lms_page.py:622 current Web element Title is : INFO  setup:lms_page.py:622 current Web element Title is : Customer Speack INFO  setup:lms_page.py:622 current Web element Title is : Corporate Training INFO  setup:lms_page.py:622 current Web element Title is : Simplilearn Community INFO  setup:lms_page.py:622 current Web element Title is : My Resources INFO  setup:lms_page.py:622 current Web element Title is : Share on LinkedIn INFO  setup:lms_page.py:622 current Web element Title is : Get the iOS App INFO  setup:lms_page.py:625 total Web element Title is : 23 INFO  setup:test_LMS_Regression_Test.py:2235 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2239 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_LMS_Dashboard_LearnerWithCertificationTab_VerfiyTabNavigation 99.37
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2256 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:618 current Web element Title is : Search Course INFO  setup:lms_page.py:622 current Web element Title is : Big Data Hadoop and Spark Developer INFO  setup:lms_page.py:622 current Web element Title is : Refer and Earn INFO  setup:lms_page.py:622 current Web element Title is : Share on Twitter INFO  setup:lms_page.py:622 current Web element Title is : In the Media INFO  setup:lms_page.py:622 current Web element Title is : Knowledge Bank INFO  setup:lms_page.py:622 current Web element Title is : Terms of Use INFO  setup:lms_page.py:622 current Web element Title is : Simplilearn INFO  setup:lms_page.py:622 current Web element Title is : Certification Programs INFO  setup:lms_page.py:622 current Web element Title is : View Disclaimer INFO  setup:lms_page.py:622 current Web element Title is : Refund Policy INFO  setup:lms_page.py:622 current Web element Title is : Become an Instructor INFO  setup:lms_page.py:625 total Web element Title is : 12 INFO  setup:test_LMS_Regression_Test.py:2280 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2284 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_LMS_Dashboard_LearnerWithSkillUpTab_VerifyTabNavigation 103.69
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2300 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:618 current Web element Title is : Search Course INFO  setup:lms_page.py:622 current Web element Title is : Agile Scrum Foundation INFO  setup:lms_page.py:622 current Web element Title is : download android app INFO  setup:lms_page.py:622 current Web element Title is : Share on Twitter INFO  setup:lms_page.py:622 current Web element Title is : In the Media INFO  setup:lms_page.py:622 current Web element Title is : Knowledge Bank INFO  setup:lms_page.py:622 current Web element Title is : Terms of Use INFO  setup:lms_page.py:622 current Web element Title is : Simplilearn INFO  setup:lms_page.py:622 current Web element Title is : Certification Programs INFO  setup:lms_page.py:622 current Web element Title is : Share on Facebook INFO  setup:lms_page.py:622 current Web element Title is : Become an Affiliate INFO  setup:lms_page.py:622 current Web element Title is : Free Trial Policy INFO  setup:lms_page.py:622 current Web element Title is : Share on Google INFO  setup:lms_page.py:622 current Web element Title is : Master's Programs INFO  setup:lms_page.py:622 current Web element Title is : View Disclaimer INFO  setup:lms_page.py:622 current Web element Title is : Get the Android App INFO  setup:lms_page.py:622 current Web element Title is : RSS Feed INFO  setup:lms_page.py:622 current Web element Title is : SkillUp INFO  setup:lms_page.py:622 current Web element Title is : Corporate Training INFO  setup:lms_page.py:622 current Web element Title is : Privacy Policy INFO  setup:lms_page.py:622 current Web element Title is : My Courses INFO  setup:lms_page.py:622 current Web element Title is : Dropdown Button INFO  setup:lms_page.py:622 current Web element Title is : Simplilearn Community INFO  setup:lms_page.py:622 current Web element Title is : Profile INFO  setup:lms_page.py:625 total Web element Title is : 24 INFO  setup:test_LMS_Regression_Test.py:2323 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2327 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_WCAG_B2C_ProgramDetailsPage_LearnerWithProgramDetailsCoursesTab_VerfiyTabNavigation 127.69
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2344 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:36 clicked on Start Program INFO  setup:lms_page.py:618 current Web element Title is : INFO  setup:lms_page.py:622 current Web element Title is : Study Central INFO  setup:lms_page.py:622 current Web element Title is : Community INFO  setup:lms_page.py:622 current Web element Title is : Dropdown Button INFO  setup:lms_page.py:622 current Web element Title is : Share on Facebook INFO  setup:lms_page.py:622 current Web element Title is : Contact Us INFO  setup:lms_page.py:622 current Web element Title is : Corporate Training INFO  setup:lms_page.py:622 current Web element Title is : View Disclaimer INFO  setup:lms_page.py:622 current Web element Title is : Profile INFO  setup:lms_page.py:622 current Web element Title is : Refer and Earn INFO  setup:lms_page.py:622 current Web element Title is : Become an Affiliate INFO  setup:lms_page.py:622 current Web element Title is : Certification INFO  setup:lms_page.py:622 current Web element Title is : Free Trial Policy INFO  setup:lms_page.py:622 current Web element Title is : Knowledge Bank INFO  setup:lms_page.py:622 current Web element Title is : About Us INFO  setup:lms_page.py:622 current Web element Title is : Share on Youtube INFO  setup:lms_page.py:622 current Web element Title is : Share on LinkedIn INFO  setup:lms_page.py:622 current Web element Title is : Customer Speack INFO  setup:lms_page.py:622 current Web element Title is : Get the Android App INFO  setup:lms_page.py:622 current Web element Title is : My Resources INFO  setup:lms_page.py:622 current Web element Title is : Share on Twitter INFO  setup:lms_page.py:622 current Web element Title is : Reschedule Policy INFO  setup:lms_page.py:625 total Web element Title is : 22 INFO  setup:test_LMS_Regression_Test.py:2372 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2376 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_ProgramExpiry_ClassicMasterProgram 69.99
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2392 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Data Scientistsshhhzzz INFO  setup:lms_page.py:440 14 INFO  setup:lms_page.py:443 14 weeks remaining INFO  setup:test_LMS_Regression_Test.py:2415 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2419 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_FreeExtension_Course_WithinOneDay 93.36
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:2437 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[contains(text(),'Get Free Extension')]") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_LMS_Regression_Test.py:2468 logging out Learner INFO  setup:test_LMS_Regression_Test.py:2472 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_ProgramExpiry_CohortExpiryLessThanMaterProgramExpiry 100.97
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:3250 test data Loaded ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:59 clicked on PG Program Tab INFO  setup:lms_page.py:60 Assigned PG Program Is Full Stack Java Developer INFO  setup:test_LMS_Regression_Test.py:3270 Course Expiry Week : 14 INFO  setup:test_LMS_Regression_Test.py:3278 Course is Expiring on : 2022-08-12 INFO  setup:test_LMS_Regression_Test.py:3281 Logging out Learner INFO  setup:test_LMS_Regression_Test.py:3286 Logout successfully INFO  setup:test_LMS_Regression_Test.py:3293 logged in to engage X INFO  setup:test_LMS_Regression_Test.py:3305 Cohort is Expiring on : 16 Jun 2022 INFO  setup:test_LMS_Regression_Test.py:3313 Cohort Expiry is less than Course Expiry INFO  setup:test_LMS_Regression_Test.py:3321 EngageX Logout Success
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_ProgramExpiry_CohortExpiryGreaterThanMaterProgramExpiry 1101.87
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:3333 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:3334 The leaner registered is : irisregression4160@yopmail.com INFO  setup:test_LMS_Regression_Test.py:3340 logged in to engage X INFO  setup:cohorts_page.py:27 clicked on cohort on side menu INFO  setup:cohorts_page.py:33 clicked on new cohort button INFO  setup:cohorts_page.py:42 mp INFO  setup:cohorts_page.py:47 MP Program Selected INFO  setup:cohorts_page.py:56 clicked on next button in stage 1 INFO  setup:cohorts_page.py:846 course name set to Full Stack Java Developer - 163 INFO  setup:cohorts_page.py:850 manager name set to Manager DL - 609111 WARNING  setup:page_factory.py:66 the locator days_list on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not visible INFO  setup:cohorts_page.py:145 extra text added to cohort name test data for LMS Regression INFO  setup:cohorts_page.py:149 Cohort Creation Status : GREAT! INFO  setup:cohorts_page.py:153 cohort created is ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression'] INFO  setup:cohorts_page.py:156 cohort name set to ['', 'MS Full Stack Java Developer Jun 2022 cohort 341test data for LMS Regression', 'PGP Data Science Jun 2022 cohort 465test data for LMS Regression', 'MS Full Stack Java Developer May 2022 cohort 342test data for LMS Regression'] ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//div[@class='cohorts-row']//div//div//a)[1]") on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not present WARNING  setup:page_factory.py:57 the locator cohort_card on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[contains(text(),'1')])[1]") on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not present INFO  setup:cohorts_page.py:941 clicked on classes tab INFO  setup:cohorts_page.py:945 clicked on New-live-classes button INFO  setup:cohorts_page.py:951 stage 4 started ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "option[value='preethi.warrier@simplilearn.net']") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3258/classes/ongoing is not present INFO  setup:cohorts_page.py:969 clicked on next button INFO  setup:cohorts_page.py:970 stage 5 started INFO  setup:cohorts_page.py:975 Test data for automation - added to class name INFO  setup:cohorts_page.py:978 clicked on next button after adding text INFO  setup:cohorts_page.py:985 class created with class name # Machine Learning JUNE 2022 batch 3Test data for CCR automation # INFO  setup:cohorts_page.py:986 stage 6 started WARNING  setup:page_factory.py:57 the locator cohort_expiry_on_card on url http://dockerv2.simplilearn.com:8877/#/cohorts/ongoing is not present INFO  setup:test_LMS_Regression_Test.py:3375 Cohort is Expiring on : 22 Dec 2022 INFO  setup:test_LMS_Regression_Test.py:3379 EngageX Logout Success INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:548 clicked on submit button on assignment page INFO  setup:assignment_page.py:551 learner registered sucessfully INFO  setup:test_LMS_Regression_Test.py:3400 Admin Logged Out INFO  setup:test_LMS_Regression_Test.py:3404 cookies Cleared INFO  setup:test_LMS_Regression_Test.py:3418 community popup notification appeared gor new learner ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_LMS_Regression_Test.py:3424 Course Expiry Week : 37 INFO  setup:test_LMS_Regression_Test.py:3432 Course is Expiring on : 2023-01-20 INFO  setup:test_LMS_Regression_Test.py:3444 Course Expiry is less than Cohort Expiry INFO  setup:test_LMS_Regression_Test.py:3449 Logging out Learner INFO  setup:test_LMS_Regression_Test.py:3454 Logout successfully
Passed test_LMS_Regression_Test.py::TestLMSRegression::test_AddLearner 1086.02
-------------------------------Captured log call--------------------------------
INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Google INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Facebook INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Linkedin INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Apple INFO  setup:test_LMS_Regression_Test.py:71 login option available with Sign Up with Email WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8561/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_LMS_Regression_Test.py:3470 Neaw Learner Created Successfully INFO  setup:test_LMS_Regression_Test.py:3471 The learner ID is : irisregression6155@yopmail.com INFO  setup:assignment_page.py:211 clicked on Assignment INFO  setup:assignment_page.py:231 clicked on submit button on assignment page INFO  setup:assignment_page.py:235 learner registered sucessfully INFO  setup:assignment_page.py:236 Program assigned successfully INFO  setup:test_LMS_Regression_Test.py:3490 Admin Logged Out INFO  setup:test_LMS_Regression_Test.py:3496 logged in to engage X INFO  setup:cohorts_page.py:459 clicked on add learner button INFO  setup:cohorts_page.py:464 searched for learner irisregression6155@yopmail.com INFO  setup:cohorts_page.py:467 user selected INFO  setup:cohorts_page.py:469 clicked on next button INFO  setup:cohorts_page.py:473 user detail verified INFO  setup:cohorts_page.py:475 clicked on Confirm button INFO  setup:cohorts_page.py:479 b2c add learner status : Request in Progress ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//a[contains(text(),'Check last request')]") on url http://dockerv2.simplilearn.com:8877/#/cohorts/upcoming/3255/learners/active is not present INFO  setup:test_LMS_Regression_Test.py:3508 page reloaded after adding class INFO  setup:test_LMS_Regression_Test.py:3510 learner count increased to 2 INFO  setup:test_LMS_Regression_Test.py:3524 Leaner Appeard in Active Learner List INFO  setup:test_LMS_Regression_Test.py:3528 EngageX Logout Success INFO  setup:test_LMS_Regression_Test.py:3543 community popup notification appeared gor new learner ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "(//a[@id='lmsWalkthoughPopupDismiss'])") on url http://dockerv5.simplilearn.com:8561/apachedev/git/paperclip/public/dashboard is not present INFO  setup:lms_page.py:64 Cohort on Program Tile : PGP Data Science Jun 2022 cohort 465test data for LMS Regression INFO  setup:test_LMS_Regression_Test.py:3550 Cohort in learner Dashboard : PGP Data Science Jun 2022 cohort 465test data for LMS Regression INFO  setup:test_LMS_Regression_Test.py:3551 Cohort Appeared in Learner Dashboard Successfully INFO  setup:test_LMS_Regression_Test.py:3554 Logging out Learner INFO  setup:test_LMS_Regression_Test.py:3559 Logout successfully
Passed test_assessment.py::TestAssessment::test_prj_no_mandatory_sbmt 44.58
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator first_project on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3128/Big-Data-Hadoop-Administrator-Course-Live/assessment is not present
Passed test_assessment.py::TestAssessment::test_project_upload_size_file_greater_than_permissible_size 85.77
No log output captured.
Passed test_assessment.py::TestAssessment::test_project_upload_size_file_lesser_than_or_equal_to_permissible_size 84.88
No log output captured.
Passed test_assessment.py::TestAssessment::test_project_successfull_upload 92.17
No log output captured.
Passed test_assessment.py::TestAssessment::test_project_unsuccessfull_upload 101.60
No log output captured.
Passed test_assessment.py::TestAssessment::test_assessment_finish_yes 46.63
No log output captured.
Passed test_assessment.py::TestAssessment::test_assessment_finish_cancel 46.68
No log output captured.
Passed test_certificate.py::TestCertificate::test_admin_programpage_visibility 48.59
-------------------------------Captured log call--------------------------------
INFO  setup:test_certificate.py:88 clicked on program management tab INFO  setup:test_certificate.py:92 clicked on program list tab INFO  setup:test_certificate.py:96 sent the program id to be searched INFO  setup:test_certificate.py:101 assert completed here for first PGP program INFO  setup:test_certificate.py:112 sent another program id to be searched INFO  setup:test_certificate.py:117 assert completed here for second PGP program INFO  setup:test_certificate.py:121 Logout successfully
Passed test_certificate.py::TestCertificate::test_admin_PGPtoCertificate_CertNotConfigured 112.79
-------------------------------Captured log call--------------------------------
INFO  setup:test_certificate.py:151 clicked on program management tab INFO  setup:test_certificate.py:154 clicked on program list tab INFO  setup:test_certificate.py:163 clicked on PGP not configure program successfully INFO  setup:test_certificate.py:167 clicked on toggle button to enable certification successfully INFO  setup:test_certificate.py:178 Passed value to certificate identifier successfully WARNING  setup:page_factory.py:57 the locator popup_confirm_btn on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/admin/program/edit/bundleId/157/name/Getting%20Started%20with%20PGP%20Data%20Science%20Program/category/Data%20Science%20&%20Business%20Analytics is not present WARNING  setup:test_certificate.py:210 Exception While Configuring Certificate !!! INFO  setup:test_certificate.py:212 Logout successfully
Passed test_certificate.py::TestCertificate::test_admin_PGPtoCertificate_CertConfigured 49.15
-------------------------------Captured log call--------------------------------
INFO  setup:test_certificate.py:243 clicked on program management tab INFO  setup:test_certificate.py:246 clicked on program list tab INFO  setup:test_certificate.py:256 Clicked PGP configured Program successfully WARNING  setup:page_factory.py:66 the locator input_certificate_identifier on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/admin/program/edit/bundleId/483/name/Post%20Graduate%20Program%20in%20Data%20Science/category/Data%20Science%20&%20Business%20Analytics is not visible WARNING  setup:page_factory.py:66 the locator input_program_display_name on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/admin/program/edit/bundleId/483/name/Post%20Graduate%20Program%20in%20Data%20Science/category/Data%20Science%20&%20Business%20Analytics is not visible INFO  setup:test_certificate.py:262 Assert successfull ...!! INFO  setup:test_certificate.py:266 Logout successfull
Passed test_certificate.py::TestCertificate::test_admin_MPtoCertificate_CertConfigured 39.25
-------------------------------Captured log call--------------------------------
INFO  setup:test_certificate.py:393 clicked on program management tab INFO  setup:test_certificate.py:396 clicked on program list tab WARNING  setup:page_factory.py:57 the locator label_MP_Configured_program on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/admin/program/list is not present
Passed test_certificate.py::TestCertificate::test_CertMod_B2C_ConfiguredPGP_BackenedAssignment 815.81
-------------------------------Captured log call--------------------------------
WARNING  setup:page_factory.py:57 the locator txt_firstname on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:57 the locator txt_lastname on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/register-email is not present WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/register-email is not visible WARNING  setup:page_factory.py:66 the locator chk_agree on url http://dockerv5.simplilearn.com:8555/apachedev/git/cloud6/public/user/register-email is not visible INFO  setup:test_certificate.py:1241 The leaner registered is : Test8543@yopmail.com INFO  setup:test_certificate.py:1271 if success message appeared ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//h5[contains(text(),'Program assigned successfully')]") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/admin/support/assign is not present INFO  setup:test_certificate.py:1316 PG Programs tab is present INFO  setup:test_certificate.py:1317 course present is Post Graduate Program in Data Science INFO  setup:test_certificate.py:1325 Certification tab is present INFO  setup:test_certificate.py:1341 Logout successfully
Passed test_certificate.py::TestCertificate::test_CertMod_B2C_ConfiguredMP_CertificationTab_LockedCourses_and_Program_UIVerification 128.88
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_certificate.py:1934 logged in to LMS as a LEARNER is successfull..!! INFO  setup:test_certificate.py:1936 master tab is present INFO  setup:test_certificate.py:1940 Data Scientistsshhhzzz course is present ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[contains(text(),'START PROGRAM')]") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_certificate.py:1953 Data Scientistsshhhzzz program assigned INFO  setup:test_certificate.py:1958 inside Courses tab INFO  setup:test_certificate.py:1962 Big Data Hadoop and Spark Developerin ellevtive tab INFO  setup:test_certificate.py:1962 Lean Managementin ellevtive tab INFO  setup:test_certificate.py:1962 Core Javain ellevtive tab INFO  setup:test_certificate.py:1968 inside Ellectives tab INFO  setup:test_certificate.py:1972 Data Science with R Programming in ellevtive tab INFO  setup:test_certificate.py:1972 Adobe Soundbooth CS5 in ellevtive tab INFO  setup:test_certificate.py:1972 Linux Training in ellevtive tab INFO  setup:test_certificate.py:1972 Math Refresher in ellevtive tab INFO  setup:test_certificate.py:1972 Statistics Essential for Data Science in ellevtive tab INFO  setup:test_certificate.py:1978 inside certification tab INFO  setup:test_certificate.py:1993 all courses present in program certificates INFO  setup:test_certificate.py:1998 Data Science with R Programming course in present inside ellective list in certification tab INFO  setup:test_certificate.py:1998 Adobe Soundbooth CS5 course in present inside ellective list in certification tab INFO  setup:test_certificate.py:1998 Linux Training course in present inside ellective list in certification tab INFO  setup:test_certificate.py:1998 Math Refresher course in present inside ellective list in certification tab INFO  setup:test_certificate.py:1998 Statistics Essential for Data Science course in present inside ellective list in certification tab INFO  setup:test_certificate.py:2002 all courses present in ellective courses INFO  setup:test_certificate.py:2011 Data Science with R Programming is LOCKED INFO  setup:test_certificate.py:2011 Adobe Soundbooth CS5 is LOCKED INFO  setup:test_certificate.py:2011 Linux Training is LOCKED INFO  setup:test_certificate.py:2011 Math Refresher is LOCKED INFO  setup:test_certificate.py:2011 Statistics Essential for Data Science is LOCKED INFO  setup:test_certificate.py:2017 all courses present inside program certificates INFO  setup:test_certificate.py:2019 all courses present inside ellective courses certificates INFO  setup:test_certificate.py:2023 Program_certifiacte is Locked INFO  setup:test_certificate.py:2026 You need to complete 3 pending courses to unlock this certificate. INFO  setup:test_certificate.py:2035 Logout successfull
Passed test_certificate.py::TestCertificate::test_CertMod_B2C_ConfiguredPGP_CertificationTab_LockedCourses_and_Program_UIVerification 96.15
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//button[@class='joyride-button']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_certificate.py:2083 PG Programs program is present INFO  setup:test_certificate.py:2087 Post Graduate Program in Data Science course assigned WARNING  setup:page_factory.py:57 the locator btn_goTo_program on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/dashboard is not present INFO  setup:test_certificate.py:2095 Certification is present INFO  setup:test_certificate.py:2100 inside Courses tab INFO  setup:test_certificate.py:2104 Big Data Hadoop and Spark Developer in Courses tab INFO  setup:test_certificate.py:2104 Power BI in Courses tab INFO  setup:test_certificate.py:2104 Introduction to Artificial Intelligence in Courses tab INFO  setup:test_certificate.py:2104 Agile Scrum Foundation in Courses tab INFO  setup:test_certificate.py:2112 inside prerequisits tab ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('xpath', "//div[@class='electiveTab ng-star-inserted']//p[@class='course-title custom-course-title-theme']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/program/post-graduates/156/Post%20Graduate%20Program%20in%20Data%20Science/prerequisites is not present INFO  setup:test_certificate.py:2120 no courses present in prerequisit tab INFO  setup:test_certificate.py:2125 inside Ellectives tab INFO  setup:test_certificate.py:2129 Aptech-Introduction to Artificial Intelligence in ellevtive tab INFO  setup:test_certificate.py:2129 Core Java in ellevtive tab INFO  setup:test_certificate.py:2129 Linux Training in ellevtive tab INFO  setup:test_certificate.py:2136 certification tab opened INFO  setup:test_certificate.py:2140 Program Certificates is present in certification tab INFO  setup:test_certificate.py:2152 all courses present in program certificates INFO  setup:test_certificate.py:2167 Elective Courses Certificates is present in certification tab INFO  setup:test_certificate.py:2170 Aptech-Introduction to Artificial Intelligence course in present inside ellective list in certification tab INFO  setup:test_certificate.py:2170 Core Java course in present inside ellective list in certification tab INFO  setup:test_certificate.py:2170 Linux Training course in present inside ellective list in certification tab INFO  setup:test_certificate.py:2174 all Courses present in elective certification tab INFO  setup:test_certificate.py:2182 Aptech-Introduction to Artificial Intelligence is LOCKED INFO  setup:test_certificate.py:2182 Core Java is LOCKED INFO  setup:test_certificate.py:2182 Linux Training is LOCKED INFO  setup:test_certificate.py:2188 all courses present inside program certificates INFO  setup:test_certificate.py:2190 all courses present inside ellective courses certificates INFO  setup:test_certificate.py:2194 Program_certifiacte is Locked INFO  setup:test_certificate.py:2197 You need to complete 3 pending courses to unlock this certificate. INFO  setup:test_certificate.py:2205 Logout successfull
Passed test_changepassword.py::TestChangePassword::test_changepassword_functionality_validation_check 40.87
No log output captured.
Passed test_changepassword.py::TestChangePassword::test_changepassword_functionality 40.29
No log output captured.
Passed test_changepassword.py::TestChangePassword::test_login_with_new_password 54.93
No log output captured.
Passed test_cohort.py::TestCohort::test_LVC_IntegrationTest_GLVCcohortClass_MyClassesTab_AddToCalenderCTA 98.15
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "div[class='addeventstc unregistertag btn info ng-star-inserted']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/3920/Phase-2---Mean/classes is not present
Passed test_elvc.py::TestElvc::test_register_for_class 386.89
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_register_button_present 403.44
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[title='Register']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_unregister_for_class 102.03
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_starting_soon_tag 387.13
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_progress_soon_tag 74.49
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_over_tag 380.50
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_myclasses_starting_soon_tag 67.66
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc.py::TestElvc::test_available_class_button_present 71.70
No log output captured.
Passed test_elvc.py::TestElvc::test_past_class_button_present 69.36
No log output captured.
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_register_for_class 86.19
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_register_button_present 378.16
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[title='Register']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_unregister_for_class 99.11
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_starting_soon_tag 394.49
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_progress_soon_tag 104.90
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_over_tag 664.18
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_myclasses_progress_soon_tag 105.43
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_elvc_1536_864_resolution.py::TestElvc1536Resolution::test_available_class_button_present 651.65
No log output captured.
Passed test_focus_course.py::TestFocusCourse::test_set_focus_course 57.51
No log output captured.
Passed test_full_access.py::TestFullAccess::test_access_selflearning 49.30
No log output captured.
Passed test_glvc.py::TestGlvc::test_register_button_present 56.87
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[title='Register']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_glvc.py::TestGlvc::test_unregister_for_class 57.03
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_glvc.py::TestGlvc::test_progress_soon_tag 366.53
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_glvc.py::TestGlvc::test_myclasses_progress_soon_tag 82.52
-------------------------------Captured log call--------------------------------
ERROR  setup:selenium_helper.py:47 Message: WARNING  setup:selenium_helper.py:48 the locator ('css selector', "[class='card-title']") on url http://dockerv5.simplilearn.com:8555/apachedev/git/paperclip/public/courses/2810/Big-Data-Hadoop-and-Spark-Developer1234/classes is not present
Passed test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_PG_user_in_program_page 34.57
-------------------------------Captured log call--------------------------------
INFO  setup:test_help&support.py:39 HnS window is displayed.
Passed test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_non_PG_user_in_dashboard_page 104.50
-------------------------------Captured log call--------------------------------
INFO  setup:test_help&support.py:58 HnS window is displayed.
Passed test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_non_PG_user_in_program_page 53.50
-------------------------------Captured log call--------------------------------
INFO  setup:test_help&support.py:82 HnS window is displayed.
Passed test_help&support.py::TestHelpAndSupport::test_help_functionality_as_b2c_PG_user_in_dashboard_page 28.76
-------------------------------Captured log call--------------------------------
INFO  setup:test_help&support.py:106 HnS window is displayed.