Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(778)

Unified Diff: components/background_task_scheduler/android/java/src/org/chromium/components/background_task_scheduler/BackgroundTaskSchedulerFactory.java

Issue 2814653003: [Android] BackgroundTaskScheduler reschedule implementation (Closed)
Patch Set: Rebasing Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/background_task_scheduler/android/java/src/org/chromium/components/background_task_scheduler/BackgroundTaskSchedulerFactory.java
diff --git a/components/background_task_scheduler/android/java/src/org/chromium/components/background_task_scheduler/BackgroundTaskSchedulerFactory.java b/components/background_task_scheduler/android/java/src/org/chromium/components/background_task_scheduler/BackgroundTaskSchedulerFactory.java
index 79705bf0da5f347ec67c7cccc08b0b9acc1f97e8..971bebbd5e0576de4f7d72fb8c0745380d30bc50 100644
--- a/components/background_task_scheduler/android/java/src/org/chromium/components/background_task_scheduler/BackgroundTaskSchedulerFactory.java
+++ b/components/background_task_scheduler/android/java/src/org/chromium/components/background_task_scheduler/BackgroundTaskSchedulerFactory.java
@@ -8,6 +8,7 @@ import android.annotation.TargetApi;
import android.os.Build;
import org.chromium.base.ThreadUtils;
+import org.chromium.base.VisibleForTesting;
/**
* A factory for {@link BackgroundTaskScheduler} that ensures there is only ever a single instance.
@@ -34,6 +35,11 @@ public final class BackgroundTaskSchedulerFactory {
return sInstance;
}
+ @VisibleForTesting
+ static void setSchedulerForTesting(BackgroundTaskScheduler scheduler) {
+ sInstance = scheduler;
+ }
+
// Do not instantiate.
private BackgroundTaskSchedulerFactory() {}
}

Powered by Google App Engine
This is Rietveld 408576698