summaryrefslogtreecommitdiff
path: root/plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java
diff options
context:
space:
mode:
authorTor Norbye <tnorbye@google.com>2014-08-19 22:27:03 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-08-19 21:25:05 +0000
commit4ca751c002784c4bfd349cc5240b045b62277c80 (patch)
treedfc17b31990e2429535609b85f6d080c4fa0d9fe /plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java
parent890d9a2952301682ffecaed4495f5f65c84c3642 (diff)
parent060e58b3afea3ea39f5ba1cb5a443ca3ebda28c8 (diff)
downloadidea-4ca751c002784c4bfd349cc5240b045b62277c80.tar.gz
Merge "Merge remote-tracking branch 'aosp/upstream-master' into merge"
Diffstat (limited to 'plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java')
-rw-r--r--plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java22
1 files changed, 13 insertions, 9 deletions
diff --git a/plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java b/plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java
index 3da6ad3d82d7..2f93b83bef09 100644
--- a/plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java
+++ b/plugins/tasks/tasks-tests/test/com/intellij/tasks/integration/live/TrelloIntegrationTest.java
@@ -29,16 +29,20 @@ public class TrelloIntegrationTest extends LiveIntegrationTestCase<TrelloReposit
@Override
protected TrelloRepository createRepository() throws Exception {
- TrelloRepository repository = new TrelloRepository(new TrelloRepositoryType());
- String token = System.getProperty("tasks.tests.trello.token");
- if (StringUtil.isEmpty(token)) {
- throw new AssertionError("Authorization token is not set");
+ try {
+ TrelloRepository repository = new TrelloRepository(new TrelloRepositoryType());
+ String token = System.getProperty("tasks.tests.trello.token");
+ assertTrue("Authorization token is not set", !StringUtil.isEmpty(token));
+ repository.setPassword(token);
+ TrelloUser user = repository.fetchUserByToken();
+ assertNotNull(user);
+ repository.setCurrentUser(user);
+ return repository;
+ }
+ catch (AssertionError ae){
+ tearDown();
+ throw ae;
}
- repository.setPassword(token);
- TrelloUser user = repository.fetchUserByToken();
- assertNotNull(user);
- repository.setCurrentUser(user);
- return repository;
}
// TODO Check closed tasks exclusion