@SmallTest
@MediumTest
@LargeTest
public void testLoginDialogHandlesDisabled() {
Bundle bundle = new Bundle();
bundle.putInt(NativeProtocol.EXTRA_PROTOCOL_VERSION, NativeProtocol.PROTOCOL_VERSION_20121101);
bundle.putString(NativeProtocol.STATUS_ERROR_TYPE, NativeProtocol.ERROR_SERVICE_DISABLED);
Intent intent = new Intent();
intent.putExtras(bundle);
MockAuthorizationClient client = new MockAuthorizationClient();
AuthorizationClient.KatanaLoginDialogAuthHandler handler = client.new KatanaLoginDialogAuthHandler();
AuthorizationClient.AuthorizationRequest request = createRequest();
client.setRequest(request);
handler.onActivityResult(0, Activity.RESULT_OK, intent);
assertNull(client.result);
assertTrue(client.triedNextHandler);
}
AuthorizationClientTests.java 文件源码
java
阅读 22
收藏 0
点赞 0
评论 0
项目:LostAndFound
作者:
评论列表
文章目录