我正在使用Google登录Authenticate with a backend server,并希望测试我是否正确使用Status#hasResolution和Status#startResolutionForResult,但我没有'知道如何触发hasResolution为true且startResolutionForResult启动活动的代码路径。
状态来自GoogleSignInResult#getStatus(),GoogleSignInResult采用this sample等代码获取。
有没有人知道一种简单的方法(手动)测试这个?
答案 0 :(得分:1)
打开手机的“设置”应用>应用> Google Play Services
>菜单> “卸载更新”。
然后您可能需要单击“禁用”按钮以禁用工厂安装的版本。
您现在可能会开始看到来自多个应用(Gmail,云端硬盘等)的大量错误通知,因为无法找到Google Play Services
。
您还应该在应用中获取onConnectionFailed
,并有意更新Play Services
。