Skip to content

Commit d2e81eb

Browse files
authored
Merge 2feeae6 into 3a4ec18
2 parents 3a4ec18 + 2feeae6 commit d2e81eb

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

firebase-crashlytics/src/androidTest/java/com/google/firebase/crashlytics/internal/CrashlyticsWorkerTest.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ public void submitTaskFromAnotherWorkerDoesNotUseLocalThreads() throws Exception
385385
Task<Integer> otherTask =
386386
crashlyticsWorker.submit(
387387
() -> {
388-
sleep(30);
388+
sleep(300);
389389
return localExecutor.getActiveCount();
390390
});
391391

@@ -395,6 +395,8 @@ public void submitTaskFromAnotherWorkerDoesNotUseLocalThreads() throws Exception
395395
// 1 active thread when doing a local task.
396396
assertThat(Tasks.await(localWorker.submit(localExecutor::getActiveCount))).isEqualTo(1);
397397

398+
sleep(1); // The test is a bit flaky without this.
399+
398400
// 0 active local threads when waiting for other task.
399401
// Waiting for a task from another worker does not block a local thread.
400402
assertThat(Tasks.await(localWorker.submitTask(() -> otherTask))).isEqualTo(0);

0 commit comments

Comments
 (0)