import pytest
from selenium.common.exceptions import WebDriverException

from wrapped_driver import WrappedDriver


def test_empty_chromedriver_path():
    """Assert error is raised if no chromedriver path is used"""
    with pytest.raises(WebDriverException):
        WrappedDriver(executable_path="", headless=True)


def test_no_chromedriver_path():
    """Assert error is raised if no chromedriver path is used"""
    with pytest.raises(TypeError):
        WrappedDriver(headless=True)

[((9, 9, 9, 42), 'pytest.raises', 'pytest.raises', ({(9, 23, 9, 41): 'WebDriverException'}, {}), '(WebDriverException)', False, 'import pytest\n'), ((10, 8, 10, 56), 'wrapped_driver.WrappedDriver', 'WrappedDriver', (), '', False, 'from wrapped_driver import WrappedDriver\n'), ((15, 9, 15, 33), 'pytest.raises', 'pytest.raises', ({(15, 23, 15, 32): 'TypeError'}, {}), '(TypeError)', False, 'import pytest\n'), ((16, 8, 16, 36), 'wrapped_driver.WrappedDriver', 'WrappedDriver', (), '', False, 'from wrapped_driver import WrappedDriver\n')]