CTS TestCase Failed: android.app.cts.DialogTest testOnSaveInstanceState
- Dominant language
- No language data
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
```
My Android version is 4.0.3 and CTS is 4.0.3_r3.
When I run the TestCase with the cmd
-----> run cts -c android.app.cts.DialogTest -m testOnSaveInstanceState
and then failed.
The log is :
01-02 00:06:22.179 3002 3015 I TestRunner: failed:
testOnSaveInstanceState(android.app.cts.DialogTest)
01-02 00:06:22.179 3002 3015 I TestRunner: ----- begin exception -----
01-02 00:06:22.179 3002 3015 I TestRunner:
01-02 00:06:22.179 3002 3015 I TestRunner:
junit.framework.AssertionFailedError
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.Assert.fail(Assert.java:47)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.Assert.assertTrue(Assert.java:20)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.Assert.assertTrue(Assert.java:27)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.app.cts.DialogTest.testOnSaveInstanceState(DialogTest.java:318)
01-02 00:06:22.179 3002 3015 I TestRunner: at
java.lang.reflect.Method.invokeNative(Native Method)
01-02 00:06:22.179 3002 3015 I TestRunner: at
java.lang.reflect.Method.invoke(Method.java:511)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:214)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:199)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTes
tCase2.java:186)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.TestCase.runBare(TestCase.java:127)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.TestResult$1.protect(TestResult.java:106)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.TestResult.runProtected(TestResult.java:124)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.TestResult.run(TestResult.java:109)
01-02 00:06:22.179 3002 3015 I TestRunner: at
junit.framework.TestCase.run(TestCase.java:118)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:169)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:154)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:53
7)
01-02 00:06:22.179 3002 3015 I TestRunner: at
android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1551)
01-02 00:06:22.179 3002 3015 I TestRunner: ----- end exception -----
It seems the line "assertTrue(d.isOnSaveInstanceStateCalled);" in
DialogTest.java is the problem.
And I check the dir /etc/permissions and find the file:
android.hardware.screen.landscape.xml
android.hardware.screen.portrait.xml
What is the reason for this ?
Waiting for your opinion,thanks!
```
Original issue reported on code.google.com by `728719...@qq.com` on 9 Apr 2013 at 10:03
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with android.app.cts.DialogTest.java at line 318 and reproduce the failure with the reported CTS command on Android 4.0.3. Trace why testOnSaveInstanceState leaves isOnSaveInstanceStateCalled false, using the provided stack trace and device configuration. Done means the cause is identified and the CTS test passes without weakening the assertion.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- mobile-dev, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100