Android 7.0 CTS问题CtsShortcutHostTestCases

host_log

05-09 10:39:07 I/ConsoleReporter: [1/1 arm64-v8a CtsShortcutHostTestCases b9cacecd] android.content.pm.cts.shortcuthost.ShortcutManagerBackupTest#testBackupAndRestore fail: junit.framework.AssertionFailedError: expected to contain regex:but was:at junit.framework.Assert.fail(Assert.java:50)

at android.content.pm.cts.shortcuthost.BaseShortcutManagerHostTest.failWithMessage(BaseShortcutManagerHostTest.java:269)

at android.content.pm.cts.shortcuthost.BaseShortcutManagerHostTest.failNotContains(BaseShortcutManagerHostTest.java:277)

at android.content.pm.cts.shortcuthost.BaseShortcutManagerHostTest.assertContainsRegex(BaseShortcutManagerHostTest.java:238)

at android.content.pm.cts.shortcuthost.BaseShortcutManagerHostTest.assertContainsRegex(BaseShortcutManagerHostTest.java:221)

at android.content.pm.cts.shortcuthost.ShortcutManagerBackupTest.doBackup(ShortcutManagerBackupTest.java:94)

at android.content.pm.cts.shortcuthost.ShortcutManagerBackupTest.testBackupAndRestore(ShortcutManagerBackupTest.java:135)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at junit.framework.TestCase.runTest(TestCase.java:168)

at junit.framework.TestCase.runBare(TestCase.java:134)

at com.android.tradefed.testtype.DeviceTestResult$1.protect(DeviceTestResult.java:81)

at com.android.tradefed.testtype.DeviceTestResult.runProtected(DeviceTestResult.java:56)

at com.android.tradefed.testtype.DeviceTestResult.run(DeviceTestResult.java:85)

at junit.framework.TestCase.run(TestCase.java:124)

at com.android.tradefed.testtype.DeviceTestCase.run(DeviceTestCase.java:180)

at com.android.tradefed.testtype.JUnitRunUtil.runTest(JUnitRunUtil.java:55)

at com.android.tradefed.testtype.JUnitRunUtil.runTest(JUnitRunUtil.java:38)

at com.android.tradefed.testtype.DeviceTestCase.run(DeviceTestCase.java:144)

at com.android.tradefed.testtype.HostTest.run(HostTest.java:253)

at com.android.compatibility.common.tradefed.testtype.ModuleDef.run(ModuleDef.java:247)

at com.android.compatibility.common.tradefed.testtype.CompatibilityTest.run(CompatibilityTest.java:439)

at com.android.tradefed.invoker.TestInvocation.runTests(TestInvocation.java:716)

at com.android.tradefed.invoker.TestInvocation.prepareAndRun(TestInvocation.java:491)

at com.android.tradefed.invoker.TestInvocation.performInvocation(TestInvocation.java:386)

at com.android.tradefed.invoker.TestInvocation.invoke(TestInvocation.java:166)

at com.android.tradefed.command.CommandScheduler$InvocationThread.run(CommandScheduler.java:471)

05-09 10:39:07 I/FailureListener: FailureListener.testFailed android.content.pm.cts.shortcuthost.ShortcutManagerBackupTest#testBackupAndRestore false false false

05-09 10:39:07 D/ModuleListener: ModuleListener.testEnded(android.content.pm.cts.shortcuthost.ShortcutManagerBackupTest#testBackupAndRestore, {})

05-09 10:39:07 D/ModuleListener: ModuleListener.testRunEnded(61316, {})

05-09 10:39:07 I/ConsoleReporter: [b9cacecd] arm64-v8a CtsShortcutHostTestCases completed in 1m 1s. 0 passed, 1 failed, 0 not executed


device_logcat

01-08 01:52:14.334  2416  2713 W BackupManagerService: Proposed transport ComponentInfo{android/com.android.internal.backup.LocalTransportService} not whitelisted; ignoring

此问题发生原因为system/etc/platform.xml文件中没有添加相应的白名单,在platform.xml中添加如下即可:

<backup-transport-whitelisted-service service="android/com.android.internal.backup.LocalTransportService"/>



最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

  • afinalAfinal是一个android的ioc,orm框架 https://github.com/yangf...
    passiontim阅读 15,757评论 2 45
  • Android 自定义View的各种姿势1 Activity的显示之ViewRootImpl详解 Activity...
    passiontim阅读 176,123评论 25 709
  • 姓名:谢新葵 公司:宁波大发化纤有限公司 宁波盛和塾《六项精进》第235期学员感谢二组 【日精进打卡第74天】 知...
    sandy201704阅读 1,058评论 0 0
  • 我想自己不那么累,我想我尽力了没,我想的和我自己能得到的并不成正比,好吧,我好累,是心累比体力还累 所有的事都得自...
    艳儿吖阅读 832评论 0 0
  • 这篇文章是关于 Ruby 语法中表达式和操作符的一些值得注意的知识点。 关键字字面量 某些 Ruby 关键字是基本...
    零小白阅读 4,944评论 0 3

友情链接更多精彩内容