Index: components/gcm_driver/instance_id/instance_id_android.h |
diff --git a/components/gcm_driver/instance_id/instance_id_android.h b/components/gcm_driver/instance_id/instance_id_android.h |
index a11529604142cc774d0a96cf0e208ef3e6386a97..f27a4867d48493af9f5ba74d5533e93f0255d9b1 100644 |
--- a/components/gcm_driver/instance_id/instance_id_android.h |
+++ b/components/gcm_driver/instance_id/instance_id_android.h |
@@ -27,6 +27,11 @@ class InstanceIDAndroid : public InstanceID { |
// Register JNI methods. |
static bool RegisterJni(JNIEnv* env); |
+ // Tests depending on InstanceID that run without a nested Java message loop |
+ // must enable this. Operations that would normally be asynchronous will |
+ // instead block the UI thread. Reset it to false when tearing down. |
+ static void SetBlockOnAsyncTasksForTesting(bool block); |
+ |
InstanceIDAndroid(const std::string& app_id); |
~InstanceIDAndroid() override; |