问题描述
run cts -m CtsLibcoreTestCases -t libcore.libcore.icu.DateIntervalFormatTest#testEndAtMidnight -o
01-07 16:35:46 I/ModuleListener: [1/1] libcore.libcore.icu.DateIntervalFormatTest#testEndAtMidnight fail:
junit.framework.ComparisonFailure: expected:<February 27, []04:00 – 00:00> but was:<February 27, [2018, ]04:00 – 00:00>
at junit.framework.Assert.assertEquals(Assert.java:85)
at junit.framework.Assert.assertEquals(Assert.java:91)
at libcore.libcore.icu.DateIntervalFormatTest.testEndAtMidnight(DateIntervalFormatTest.java:442)
at java.lang.reflect.Method.invoke(Native Method)
junit.framework.ComparisonFailure: expected:<February 27, []04:00 – 00:00> but was:<February 27, [2018, ]04:00 – 00:00>
at junit.framework.Assert.assertEquals(Assert.java:85)
at junit.framework.Assert.assertEquals(Assert.java:91)
at libcore.libcore.icu.DateIntervalFormatTest.testEndAtMidnight(DateIntervalFormatTest.java:442)
at java.lang.reflect.Method.invoke(Native Method)
解决方案
这个fail google 有soluton,但是还没有合入到正式的release中,google solution:
https://android.googlesource.com/platform/libcore/+/fc7b371715bc4075275e5b2be5b1a46c789baee3
因此,用最新的daily build 跑pass即可;
CTS测试用如下这版daily build tool包测试pass
5210781 | N/A | SUCCESSFUL | 2019 Jan 5 05:41:42 |
第二个实验测试cts-on-gsi:
把上面提到的这个包里的两只档替换到vts-9.0_r4包里也是pass的;
CtsLibcoreTestCases.apk
CtsLibcoreTestCases.config
因此,可以确定这是google issue;