/** * It's valid to call exec with a non-string key, but we'd better blow up already before casting a * random object to String, or converting it using toString() */ @Test public void canceledWhenNonStringKey() throws InterruptedException { getter.exec(new Object()); assertEquals( "Getter was not correctly cancelled for non-String url", getter.getStatus(), Task.CANCELED); }