Appium Android : Not able to locate ListView elements


I’m using Appium 1.2.1 on Mac OS for automating android app.
I have to locate a ListView which consist of 8 items. I tried to do this using below code

List MenuChoices = driver.findElements(By.xpath("//android.view.View[2]/android.widget.FrameLayout[1]/android.widget.ListView[]"));

Result shows count as 1, that means list is not identifed

Please help to sort this out.

I’m facing similar issue. In my case, this list appears on scrolling the page down. The same code works if I add a breakpoint before locating the object and scroll the page down manually and then continue it.

      @AndroidFindBy(uiAutomator = "new UiSelector().resourceId(\"pkg:id/test\")")
      List<MobileElement> abc;