Awex { @SuppressWarnings("unchecked") public <Result, Progress> Promise<Result, Progress> absent() { return (Promise<Result, Progress>) mAbsentPromise; } Awex(ThreadHelper threadHelper, Logger logger, PoolPolicy poolPolicy); Promise<Result, Progress> submit(final Task<Result, Progress> task); void cancel(Task<Result, Progress> task, boolean mayInterrupt); @SafeVarargs final Promise<Result, Progress> sequentiallyUntilFirstDone(final
    Task<Result, Progress>... tasks); Promise<Result, Progress> sequentiallyUntilFirstDone(final
    Collection<Task<Result, Progress>> tasks); @SafeVarargs final Promise<Collection<Result>, Progress> allOf(Promise<Result, Progress>... promises); Promise<Collection<Result>, Progress> allOf(Collection<Promise<Result, Progress>> promises); @SafeVarargs final Promise<Result, Progress> anyOf(Promise<Result, Progress>... promises); Promise<Result, Progress> anyOf(Collection<Promise<Result, Progress>> promises); @SafeVarargs final Promise<MultipleResult<Result, Progress>, Progress> afterAll(Promise<Result, Progress>... promises); Promise<MultipleResult<Result, Progress>, Progress> afterAll(Collection<Promise<Result, Progress>> promises); @SuppressWarnings("unchecked") Promise<Result, Progress> of(Result value); ResolvablePromise<Result, Progress> newAwexPromise(); @SuppressWarnings("unchecked") Promise<Result, Progress> absent(); @Override String toString();  }
@Test public void shouldCreateARejectedPromise() { setUpAwex(); Promise<Integer, Float> promise = mAwex.absent(); assertTrue(promise.isRejected()); }