-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
3 changed files
with
7 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,6 @@ | |
import org.json.JSONObject; | ||
import org.junit.After; | ||
import org.junit.Before; | ||
import org.junit.Ignore; | ||
import org.junit.Test; | ||
import org.junit.runner.RunWith; | ||
import org.mockito.Mockito; | ||
|
@@ -66,6 +65,11 @@ | |
import static org.junit.Assert.fail; | ||
import static org.mockito.Mockito.mock; | ||
|
||
/** | ||
* | ||
* | ||
* Created by Ephraim Kigamba - [email protected] on 05/12/2017. | ||
*/ | ||
@RunWith(RobolectricTestRunner.class) | ||
@Config(manifest = Config.NONE, | ||
shadows = { | ||
|
@@ -85,7 +89,7 @@ public class MapboxOfflineDownloaderServiceTest { | |
private Context context; | ||
private MapboxOfflineDownloaderService mapboxOfflineDownloaderService; | ||
|
||
private final String sampleValidMapboxStyleURL = "mapbox://styles/ona/90kiosdcIJ3d"; | ||
private String sampleValidMapboxStyleURL = "mapbox://styles/ona/90kiosdcIJ3d"; | ||
private String mapboxAccessToken; | ||
private float minZoom = 22; | ||
private float maxZoom = 10; | ||
|
@@ -241,19 +245,16 @@ public void persistOfflineMapTaskShouldSaveQueueTaskWhenGivenValidDownloadTask() | |
} | ||
|
||
@Test | ||
@Ignore("Hanging on CI") | ||
public void sendBroadcastShouldProduceValidIntentWhenGivenDownloadUpdate() { | ||
assertValidBroadcastCreatedWhenSendBroadcastIsCalled(MapboxOfflineDownloaderService.SERVICE_ACTION_RESULT.SUCCESSFUL, mapName, "9.0%", MapboxOfflineDownloaderService.SERVICE_ACTION.DOWNLOAD_MAP); | ||
} | ||
|
||
@Test | ||
@Ignore("Hanging on CI") | ||
public void sendBroadcast2ShouldProduceValidIntentWhenGivenDownloadUpdate() { | ||
assertValidBroadcastCreatedWhenSendBroadcast2IsCalled(MapboxOfflineDownloaderService.SERVICE_ACTION_RESULT.SUCCESSFUL, mapName, MapboxOfflineDownloaderService.SERVICE_ACTION.DELETE_MAP); | ||
} | ||
|
||
@Test | ||
@Ignore("Hanging on CI") | ||
public void mapboxTileLimitExceededShouldCreateValidBroadcast() throws InterruptedException, NoSuchFieldException, IllegalAccessException { | ||
latch = new CountDownLatch(1); | ||
|
||
|
@@ -269,7 +270,6 @@ public void mapboxTileLimitExceededShouldCreateValidBroadcast() throws Interrupt | |
} | ||
|
||
@Test | ||
@Ignore("Failing : To Do Fix") | ||
public void onErrorShouldCreateValidBroadcastWhenGivenNonEmptyReasonAndMessage() throws NoSuchFieldException, IllegalAccessException { | ||
latch = new CountDownLatch(1); | ||
|
||
|
@@ -286,7 +286,6 @@ public void onErrorShouldCreateValidBroadcastWhenGivenNonEmptyReasonAndMessage() | |
} | ||
|
||
@Test | ||
@Ignore("Hanging on CI") | ||
public void onErrorShouldCreateValidBroadcastWhenGivenNonEmptyReasonAndEmptyMessage() throws NoSuchFieldException, IllegalAccessException, InterruptedException { | ||
latch = new CountDownLatch(1); | ||
|
||
|
@@ -304,7 +303,6 @@ public void onErrorShouldCreateValidBroadcastWhenGivenNonEmptyReasonAndEmptyMess | |
} | ||
|
||
@Test | ||
@Ignore("Hanging on CI") | ||
public void onStatusChangedShouldShowProgressNotificationWhenGivenIncompleteOfflineRegionStatus() throws NoSuchFieldException, IllegalAccessException, InterruptedException, NoSuchMethodException, InvocationTargetException { | ||
latch = new CountDownLatch(1); | ||
OfflineRegionStatus incompleteOfflineRegionStatus = createOfflineRegion(OfflineRegion.STATE_ACTIVE, 200, 98923, 898, 230909, 300, true, false); | ||
|
@@ -427,7 +425,6 @@ public void getTaskStatusShouldUpdateCurrentDownloadMapNameWhenGivenValidDeleteQ | |
} | ||
|
||
@Test | ||
@Ignore("Hanging on CI") | ||
public synchronized void onStatusChangedShouldShowDownloadCompleteNotificationWhenGivenCompletedOfflineRegion() throws Throwable { | ||
latch = new CountDownLatch(1); | ||
OfflineRegionStatus completeOfflineRegionStatus = createOfflineRegion(OfflineRegion.STATE_ACTIVE, 300, 98923, 898, 230909, 300, true, true); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters