### Question:
ExecutorDependencies { public String getPathToDriverExecutable() throws IOException { pathToDriverExecutable = Optional.ofNullable(pathToDriverExecutable).orElse(System.getenv(DRIVER_EXECUTABLE)); if (!Optional.ofNullable(pathToDriverExecutable).isPresent()) { throw new IOException("Path to driver executable not set. Please either set it using" + " pathToDriverExecutable method or by setting the environment variable" + " DRIVER_EXECUTABLE"); } return pathToDriverExecutable; }  ExecutorDependencies pathToDriverExecutable(String pathToDriverExecutable); ExecutorDependencies javascriptInjectionCode(String javascriptInjectionCode); ExecutorDependencies timeoutInSeconds(Integer timeout); ExecutorDependencies measurementsPrecisionInMilliseconds(Integer measurementsPrecisionMilli); ExecutorDependencies maxRetries(Integer maxRetries); ExecutorDependencies baseURL(String baseURL); ExecutorDependencies automationResultBuilder(AutomationResultBuilder automationResultBuilder); ExecutorDependencies eventSynchronizer(EventSynchronizer eventSynchronizer); String getBaseURL(); String getPathToDriverExecutable(); int getTimeout(); int getMeasurementsPrecisionMilli(); int getMaxRetries(); AutomationResultBuilder getAutomationResultBuilder(); String getJavascriptInjectionCode(); EventSynchronizer getEventSynchronizer(); NoHttpRequestsInQueue noHttpRequestsInQueue(); WebDriverActionExecutionException webDriverActionExecutionException(String message, Throwable e); ExecutorDependencies screenToUse(String screen); String getScreenToUse(); ExecutorDependencies screenNumber(int screen); int getScreenNumber(); ExecutorDependencies replayingState(ReplayingState replayingState); ReplayingState getReplayingState(); DriverOperations getDriverOperations(); ExecutorDependencies driverOperations(DriverOperations driverOperations);  }### Answer:
@Test public void throwsExceptionIfDriverIsNotSet() throws IOException { ExecutorDependencies executorDependencies = new ExecutorDependencies(); expectedException.expect(IOException.class); executorDependencies.getPathToDriverExecutable(); }