()
| 178 | } |
| 179 | |
| 180 | public void testBackgroundError() { |
| 181 | runTaskTest(new Callable<Task<?>>() { |
| 182 | public Task<?> call() throws Exception { |
| 183 | return Task.callInBackground(new Callable<Integer>() { |
| 184 | public Integer call() throws Exception { |
| 185 | throw new IllegalStateException(); |
| 186 | } |
| 187 | }).continueWith(new Continuation<Integer, Void>() { |
| 188 | public Void then(Task<Integer> task) { |
| 189 | assertTrue(task.isFaulted()); |
| 190 | assertTrue(task.getError() instanceof IllegalStateException); |
| 191 | return null; |
| 192 | } |
| 193 | }); |
| 194 | } |
| 195 | }); |
| 196 | } |
| 197 | |
| 198 | public void testWhenAllSuccess() { |
| 199 | runTaskTest(new Callable<Task<?>>() { |
nothing calls this directly
no test coverage detected