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)

[((226, 259), 'pytest.raises', 'pytest.raises', (['WebDriverException'], {}), '(WebDriverException)\n', (239, 259), False, 'import pytest\n'), ((269, 317), 'wrapped_driver.WrappedDriver', 'WrappedDriver', ([], {'executable_path': '""""""', 'headless': '(True)'}), "(executable_path='', headless=True)\n", (282, 317), False, 'from wrapped_driver import WrappedDriver\n'), ((427, 451), 'pytest.raises', 'pytest.raises', (['TypeError'], {}), '(TypeError)\n', (440, 451), False, 'import pytest\n'), ((461, 489), 'wrapped_driver.WrappedDriver', 'WrappedDriver', ([], {'headless': '(True)'}), '(headless=True)\n', (474, 489), False, 'from wrapped_driver import WrappedDriver\n')]