Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9105429
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T02:06:21+00:00 2026-06-17T02:06:21+00:00

In testing with Robotium, how select a element of the listView in fragment ?

  • 0

In testing with Robotium, how select a element of the listView in fragment ?
I have 2 fragment Container in layout :

>     <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
>      ... 
>         <FrameLayout
>             xmlns:android="http://schemas.android.com/apk/res/android"
>             android:id="@+id/fragment_container_left"
>         ... />
>         <FrameLayout
>             xmlns:android="http://schemas.android.com/apk/res/android"
>             android:id="@+id/fragment_container_rigth"
>          .../>
>     />

and each fragment are load with the following code :

> <ListView
>     android:id="@+id/listView1" 
>  ... />

and my testing is the following :

@Override
protected void setUp() throws Exception {
    super.setUp();
    mActivity = getActivity();
    mIns = this.getInstrumentation();
    solo = new Solo(mIns, mActivity);
}
public void testBackButton() {

      // click in listView
      solo.clickInList(0);
      solo.clickInList(0);               
 ... }

the problem is that solo.clickInList(0), always being done click the ListView element belonging to the fragment on the right laden.
how do to “solo.clickInList()” click the list on the left here image ??

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T02:06:22+00:00Added an answer on June 17, 2026 at 2:06 am

    There’s a solo.clickInList(0, integer); that lets you specify which list to click. Did you try that? You can also click on a specific text.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm testing my android app using robotium , I have used fragments in my
Has anyone used Robotium or Calculon for testing Android apps? Are they useful? Any
I had done automation testing in my android application, I used robotium framework. Still
I've just started learning to use Robotium for testing my app. I have written
Right now im testing on Android 4.1.1 . using Robotium and trying to click
I am new in android testing I am using Robotium for testing purpose and
I have been involved in doing web automation and Android automation testing. Currently we
I am actually using Robotium testing framework for Android, but I believe it's based
I use Robotium Framework for Android testing purpose and manually take component_id or index
I am new to robotium testing. I wanted to open the emaulator and install

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.