debugging messages
This commit is contained in:
parent
bea18afa60
commit
895d189302
@ -42,5 +42,5 @@ jobs:
|
|||||||
- name: Run the pytests
|
- name: Run the pytests
|
||||||
run: pytest -c pytest.ini -m edge
|
run: pytest -c pytest.ini -m edge
|
||||||
|
|
||||||
- name: Run the behave tests
|
# - name: Run the behave tests
|
||||||
run: behave
|
# run: behave
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
# pylint: disable=too-few-public-methods
|
# pylint: disable=too-few-public-methods
|
||||||
|
import os
|
||||||
import platform
|
import platform
|
||||||
|
|
||||||
from selenium import webdriver
|
from selenium import webdriver
|
||||||
from selenium.webdriver.chrome.options import Options as ChromeOptions
|
from selenium.webdriver.chrome.options import Options as ChromeOptions
|
||||||
from selenium.webdriver.firefox.options import Options as FirefoxOptions
|
|
||||||
from selenium.webdriver.edge.options import Options as EdgeOptions
|
from selenium.webdriver.edge.options import Options as EdgeOptions
|
||||||
from selenium.webdriver.edge.service import Service as EdgeService
|
from selenium.webdriver.edge.service import Service as EdgeService
|
||||||
|
from selenium.webdriver.firefox.options import Options as FirefoxOptions
|
||||||
|
|
||||||
from conftest import CWD
|
from conftest import CWD
|
||||||
import os
|
|
||||||
|
|
||||||
|
|
||||||
class BrowserDriver:
|
class BrowserDriver:
|
||||||
@ -45,9 +46,12 @@ def edge(headless=True):
|
|||||||
driver_name += ".exe"
|
driver_name += ".exe"
|
||||||
edgedriver_loc = os.path.join(CWD, 'drivers', driver_name)
|
edgedriver_loc = os.path.join(CWD, 'drivers', driver_name)
|
||||||
|
|
||||||
print("***** DRIVER LOCATION *****")
|
print("***** DRIVER DEFINED LOCATION *****")
|
||||||
print(edgedriver_loc)
|
print(edgedriver_loc)
|
||||||
print("***** DRIVER LOCATION *****")
|
if os.path.isfile(edgedriver_loc):
|
||||||
|
print(f'\nThe file {edgedriver_loc} exists.\n')
|
||||||
|
else:
|
||||||
|
print(f'\nThe file {edgedriver_loc} does not exist!\n')
|
||||||
|
|
||||||
options.use_chromium = True
|
options.use_chromium = True
|
||||||
options.add_argument('disable-gpu')
|
options.add_argument('disable-gpu')
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import pytest
|
import pytest
|
||||||
|
|
||||||
from browserdriver import BrowserDriver
|
from browserdriver import BrowserDriver
|
||||||
from conftest import CWD
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.firefox
|
@pytest.mark.firefox
|
||||||
@ -34,4 +33,3 @@ def test_edge_browser(headless):
|
|||||||
bd.get('https://test.io')
|
bd.get('https://test.io')
|
||||||
assert bd.title == "Home | Test IO"
|
assert bd.title == "Home | Test IO"
|
||||||
bd.quit()
|
bd.quit()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user