landryshuai / robotium

Automatically exported from code.google.com/p/robotium
0 stars 0 forks source link

Xpath testcase fails in android for version less than 4 #542

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

1. Playing back webapp by xpath in android version less than 4, it 
fails.(checking with android 2.3   Emulator and galaxy tab )

2.Nexus works fine

What is the expected output? What do you see instead?

Common webelement xpath, need to work an all the devices.

What version of the product are you using? On what operating system?

Robotium 4.3

Please provide any additional information below.

Attached log details:

10-24 16:24:06.349: I/TestRunner(30946): failed: 
testmedmo(com.robo.common.test.SamAppTestApk)
10-24 16:24:06.349: I/TestRunner(30946): ----- begin exception -----
10-24 16:24:06.429: I/TestRunner(30946): junit.framework.AssertionFailedError: 
WebElement with xpath: '//div[@id='root']/div[2]/div/div/div/a/span/div' is not 
found!
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.Assert.fail(Assert.java:47)
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.Assert.assertTrue(Assert.java:20)
10-24 16:24:06.429: I/TestRunner(30946):    at 
com.jayway.android.robotium.solo.Clicker.clickOnWebElement(Clicker.java:343)
10-24 16:24:06.429: I/TestRunner(30946):    at 
com.jayway.android.robotium.solo.Solo.clickOnWebElement(Solo.java:890)
10-24 16:24:06.429: I/TestRunner(30946):    at 
com.robo.common.test.SamAppTestApk.testmedmo(SamAppTestApk.java:43)
10-24 16:24:06.429: I/TestRunner(30946):    at 
java.lang.reflect.Method.invokeNative(Native Method)
10-24 16:24:06.429: I/TestRunner(30946):    at 
java.lang.reflect.Method.invoke(Method.java:507)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:204)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:194)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTes
tCase2.java:186)
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.TestCase.runBare(TestCase.java:127)
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.TestResult$1.protect(TestResult.java:106)
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.TestResult.runProtected(TestResult.java:124)
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.TestResult.run(TestResult.java:109)
10-24 16:24:06.429: I/TestRunner(30946):    at 
junit.framework.TestCase.run(TestCase.java:118)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:169)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:154)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:52
9)
10-24 16:24:06.429: I/TestRunner(30946):    at 
android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1448)
10-24 16:24:06.429: I/TestRunner(30946): ----- end exception -----
10-24 16:24:06.498: I/TestRunner(30946): finished: 
testmedmo(com.robo.common.test.SamAppTestApk)

Note:
In google "Issue attachment storage quota exceeded".

So i attached files in host.

http://www.mediafire.com/?nn6ohf26k4c0v11

Original issue reported on code.google.com by chokkarb...@gmail.com on 24 Oct 2013 at 11:46

GoogleCodeExporter commented 9 years ago
Thanks for reporting this. 

Original comment by renasr...@gmail.com on 25 Oct 2013 at 6:14

GoogleCodeExporter commented 9 years ago
Will open up when there is time to do something about this. 

Original comment by renasr...@gmail.com on 4 Nov 2013 at 4:35