Fix a couple problems related to getting and deleting Instance ID
commitea853487662ff24e21c667537d420145439ecc9d
authorjianli <jianli@chromium.org>
Mon, 22 Jun 2015 21:06:22 +0000 (22 14:06 -0700)
committerCommit bot <commit-bot@chromium.org>
Mon, 22 Jun 2015 21:06:48 +0000 (22 21:06 +0000)
tree291231f9de93c34d350db5d2ecf3124cf91ec9d3
parent64b639183a8ff8f4c4d010358e546620d54b2f93
Fix a couple problems related to getting and deleting Instance ID

Problems fixed:
1) Add/Remove/Get InstanceID data should be delayed until GCMClient
   is ready
2) Unregistration request should not be triggered if no token has
   been retrieved

BUG=502385
TEST=new tests
NOTRY=TRUE

Review URL: https://codereview.chromium.org/1192753006

Cr-Commit-Position: refs/heads/master@{#335558}
components/gcm_driver/fake_gcm_client.cc
components/gcm_driver/fake_gcm_client.h
components/gcm_driver/gcm_client_impl.cc
components/gcm_driver/gcm_client_impl_unittest.cc
components/gcm_driver/gcm_driver_desktop.cc
components/gcm_driver/gcm_driver_desktop.h
components/gcm_driver/gcm_driver_desktop_unittest.cc