Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed android sample tests. #40

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Jun 11, 2014

  1. Fixed android sample tests.

    Upgrading to robotium 4.3.1 fixed this exception (when run on a 4.4 emulator):
    
    ```
    java.lang.RuntimeException: java.lang.ClassCastException: java.util.ArrayList cannot be cast to android.view.View[]
    at com.jayway.android.robotium.solo.Searcher.searchFor(Searcher.java:127)
    at com.jayway.android.robotium.solo.Waiter.waitForText(Waiter.java:383)
    at com.jayway.android.robotium.solo.Clicker.clickOn(Clicker.java:352)
    at com.jayway.android.robotium.solo.Solo.clickOnButton(Solo.java:742)
    at com.octo.android.sample.test.HelloAndroidActivityFestAndroidTest.testCompute(HelloAndroidActivityFestAndroidTest.java:25)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:214)
    at android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:199)
    at android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:192)
    at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:191)
    at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:176)
    at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:554)
    at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
    Caused by: java.lang.ClassCastException: java.util.ArrayList cannot be cast to android.view.View[]
    at com.jayway.android.robotium.solo.ViewFetcher.getWindowDecorViews(ViewFetcher.java:389)
    at com.jayway.android.robotium.solo.ViewFetcher.getAllViews(ViewFetcher.java:81)
    at com.jayway.android.robotium.solo.ViewFetcher.getViews(ViewFetcher.java:189)
    at com.jayway.android.robotium.solo.ViewFetcher.getCurrentViews(ViewFetcher.java:308)
    at com.jayway.android.robotium.solo.ViewFetcher.getCurrentViews(ViewFetcher.java:295)
    at com.jayway.android.robotium.solo.Searcher$1.call(Searcher.java:112)
    at com.jayway.android.robotium.solo.Searcher$1.call(Searcher.java:106)
    at com.jayway.android.robotium.solo.Searcher.searchFor(Searcher.java:203)
    at com.jayway.android.robotium.solo.Searcher.searchFor(Searcher.java:125)
    ... 18 more
    ```
    Heath Borders committed Jun 11, 2014
    Configuration menu
    Copy the full SHA
    a62538e View commit details
    Browse the repository at this point in the history