From 9e232254ab5e7ac3c4e8bc9bba0319a167ac3927 Mon Sep 17 00:00:00 2001 From: Lode Hoste Date: Sat, 23 May 2015 12:46:21 +0200 Subject: [PATCH] Clarify todo comments --- .../test/syncthing/PollWebGuiAvailableTaskTest.java | 2 +- .../nutomic/syncthingandroid/test/syncthing/RestApiTest.java | 4 ++-- .../java/com/nutomic/syncthingandroid/syncthing/RestApi.java | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/PollWebGuiAvailableTaskTest.java b/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/PollWebGuiAvailableTaskTest.java index 2473f0cd..2d77e43f 100644 --- a/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/PollWebGuiAvailableTaskTest.java +++ b/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/PollWebGuiAvailableTaskTest.java @@ -43,6 +43,6 @@ public class PollWebGuiAvailableTaskTest extends AndroidTestCase { }.execute(mConfig.getWebGuiUrl()); latch.await(1, TimeUnit.SECONDS); - // TODO? SyncthingRunnable.killSyncthing(); + // TODO: Unit tests fail when Syncthing is killed SyncthingRunnable.killSyncthing(); } } diff --git a/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/RestApiTest.java b/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/RestApiTest.java index 9cf345bf..39860cbc 100644 --- a/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/RestApiTest.java +++ b/src/androidTest/java/com/nutomic/syncthingandroid/test/syncthing/RestApiTest.java @@ -39,7 +39,7 @@ public class RestApiTest extends AndroidTestCase { } }.execute(config.getWebGuiUrl()); mApi = new RestApi(getContext(), config.getWebGuiUrl(), config.getApiKey(), - null, null, // TODO + null, null, new RestApi.OnApiAvailableListener() { @Override public void onApiAvailable() { @@ -52,7 +52,7 @@ public class RestApiTest extends AndroidTestCase { @Override protected void tearDown() throws Exception { super.tearDown(); - // TODO? SyncthingRunnable.killSyncthing(); + // TODO: Unit tests fail when Syncthing is killed SyncthingRunnable.killSyncthing(); ConfigXml.getConfigFile(new MockContext(getContext())).delete(); } diff --git a/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java b/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java index 0826c364..f380e180 100644 --- a/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java +++ b/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java @@ -356,7 +356,7 @@ public class RestApi implements SyncthingService.OnWebGuiAvailableListener, new PostTask(mHttpsCertPath) .execute(mUrl, PostTask.URI_CONFIG, mApiKey, mConfig.toString()); } - // TODO Should wait for completion... + // TODO Should wait until PostTask is completed, see #398 if (mRestartPostponed) return;