### Question:
AbstractTask implements Task<V> { @Override public V get() throws InterruptedException, ExecutionException { while(!hasEnded.get()) { synchronized (this) { wait(); } } return getResultAfterHasEnded(); }  @Override void addTaskListener(TaskListener l); @Override void removeTaskListener(TaskListener l); @Override void setProgressEndpoints(double begin, double end); double getBeginProgress(); double getEndProgress(); @Override V get(); @Override V get(long timeout, TimeUnit unit); boolean isPaused(); synchronized void pause(); synchronized void play(); void reset(); final void run(); boolean cancel(boolean mayInterruptIfRunning); @Override /** * This version is mandated by the Future<V> interface. */ boolean isCancelled(); boolean isDone(); String getErrorMessage(); Throwable getError(); double getProgress(); boolean isBegun(); boolean isEnded(); final TaskOutcome getTaskOutcome();  }### Answer:
@Test(expected=TimeoutException.class) public void testGetWithNoStartOfTask() throws InterruptedException, ExecutionException, TimeoutException { AbstractTask<String> instance = new CapitalizeStringTask("a string to capitalize"); String result = instance.get(1L, TimeUnit.MILLISECONDS); }