简体   繁体   中英

how to access the Menu's which is placed in the action Bar(in Android Phones) in Robotium

|----------------------------------------------|
| **Menu1**|**Menu2**|**Menu3**                |
|----------------------------------------------|                                              |
|                                              |
|                                              |
|                                              | 
|                                              |
-----------------------------------------------|                                              | 

Tried with all the options such clickOnImage, ClickonImageButton,ClickonMenu, ClickonMenuItem,ClickonText etc.. but none of the methods work.. please let me know the way to access the Menu placed in the ActionBar...

您可以使用:

getInstrumentation().invokeMenuActionSync(mActivity, R.id.menu_item_id, 0);

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM