summaryrefslogtreecommitdiff
path: root/library/core-src/com/android/uiautomator/core
AgeCommit message (Collapse)Author
2013-09-19shuffling unbundled UI automator source codeGuang Zhu
* remove shell based UI automator code * port API checks from shell based to instrumentation based UI automator makefile * reorganize code structure Bug: 10793010 Change-Id: I936ded6c73f037fa15466b184826b14a1a204074
2013-06-17fix buildGuang Zhu
Change-Id: I00868d5550c665340656fe1a4f20eaa3740ea50b
2013-06-17Merge "docs: Edited Javadoc comments in uiautomator library source files ↵quddusc
(MR2)." into jb-mr2-dev
2013-06-17docs: Edited Javadoc comments in uiautomator library source files (MR2).quddusc
Change-Id: I3eff0160ecb4769f2a7b26af68794f761dbd5cbc
2013-06-13guard against use of UiDevice prior to its initializationGuang Zhu
The source of UI automation permission use to come from the fact that the test is running as shell or root user; in this case, it's fine to statically initialize UiDevice. When running as an Instrumentation, the source of UI automation permission comes from the privileged token created by system and passed down via Instrumentation context; in this case, UiDevice is not properly initialized until it has received the UiAutomation instance. The particular problem happens when statically declared UiObject makes use of UiDevice#getAutomatorBridge() too early: UiObject really shouldn't be declared statically Change-Id: If0ecab9960c588c096ed2fb8cc431ef79caa963e
2013-05-13Merge "Fix for UiDevice press button operations wait for idle" into jb-mr2-devGuang Zhu
2013-05-10Fix for UiDevice press button operations wait for idleAdam Momtaz
This cl#299334 attempted to address a missing wait for idle on the UiDevice main pressXXX operation since issues related to reliability were surfacing. These are pressHome, pressBack and pressMenu. In error, I added the waitForIdle after and not before the operation where it should've been in the first place. Operations should never count on other operations to guarantee waitForIdle for them. Each operation should ensure its own device idle before performing any action. The existing implementation unfortunately didn't improve the reliability and issues remained. This fix should put these pressXXX commands inline with all the UiAutomator APIs where everything performs a waitForIdle _before_ performing any action. Change-Id: I76d7ec50fb822d41a0be4808a0d3e61bdde17935
2013-05-09API Cleanup: return types and consitent function namesGuang Zhu
New event injection APIs are now returning true of false Functions are renamed to be more consistent Bug: 8872114 Change-Id: I3a82305e7af094eb9c9fb2393b2f3e101e84dead
2013-05-09Fix to precompile regex in UiSelectorAdam Momtaz
Also added public UiSelector#resourceIdMatches Change-Id: Ieb8a5d6fcdfdfa8c52c6ad3f2f202ec7ed4e69a5
2013-04-19Added support for global action APIs and fixed WaitForIdleAdam Momtaz
- Added openNotification and openQuickSettings to UiDevice. - Adjusted for all UiDevice presses and special key injections to perform waitForIdle after each operation. - Also screen rotations did not perform waitForIdle and now they do. Change-Id: I15784c62278a4f712d08fd081634f48d5dbcabc8
2013-04-18Fixes for UiSelector ignoring instance criterionAdam Momtaz
Reported by an external user. Information is in associated bug: 8657729 Change-Id: I5f6314d132dc167be3f06dca315947408d54d713
2013-04-16use SDK to build instrumentation based UI AutomatorGuang Zhu
Change-Id: I0fa2d4a7cd3b0df8d752d1b76cb6762d52efcf08
2013-04-15Fix for shell uiautomator to support monkey flagAdam Momtaz
Change-Id: I95f5e7567954940464c51289344ca53d7bd7d81f
2013-04-11Allow for declaring a test as a monkey type testAdam Momtaz
This enables users to write tests that act like monkey and at the same time allowing apps to react as if an android monkey test is running. bug: 8588857 Change-Id: I43ca663c2aac43658f5bb39eabe2d904d1e9009a
2013-03-14function to ensure visibility of child item inside a scrollableGuang Zhu
current implementation is experimental, with 2 restrictions: * may scroll item off screen * does not check if item fits or not (e.g. larger than screen) Change-Id: I677d0f5c22b0e60a5cb9ca6893311daf13729d14
2013-03-12DO NOT MERGE - UiObject did not perform the wait waitForObject() in UiWatchersAdam Momtaz
The UiWatcher in test libraries use the UiObject#waitForObject to wait for certain conditions to come true, however polling for object state was unecessarly disallowed. Initially the rational was to prevent the UiWatcher code from blocking too long, but this doesn't prevent the UiWatcher from using system sleep and blocking anyway. Change-Id: Icd086e696f903ddc409ce8eabaa87c99648a90b5
2013-03-12DO NOT MERGE - Allow for toggling of layout hierarchy compressionAdam Momtaz
When the compression feature is set, the accessibility layout hierarchy will only show important nodes and will remove unnecessary surrounding layouts making the hierarchy more human readable and efficient to search. The compressed hierarchy will be the default. Previous tests which depended on the more verbose hierarchy, will either need to update their selectors, or disable this feature from the UiDevice. However, the uiautomatorviewer will always show the hierarchy in its compressed form to encourage the user of the more compact and efficient selectors. Change-Id: I1d5d909ce7d4f60108dc491348fcf8da8549806c
2013-02-21UiSelector support for resource-id wasn't quite rightAdam Momtaz
Change-Id: If97edcbdfc9593977860c9ee1b086adfdf0a49c3
2013-02-14Add configuration setting options to UiAutomatorAdam Momtaz
This enables tests to modify the default timeouts and other settings in the framework. This exposes a Configurator that can be obtained by calling its static getInstance(). The settings can be changed while tests are running. Change-Id: I86575b00463fb2877711898fa8fa1c54bfa0e7b9
2013-02-12Updating the UiAutomator due to framework API change.Svetoslav
Related to change:https://googleplex-android-review.googlesource.com/#/c/273118/ bug:8183223 Change-Id: I04b143daa8588059a56f9904ad69875de687429d
2013-02-11Merge "Adds UiAutomator 'drag' APIs to UiObject and UiDevice"Adam Momtaz
2013-02-11Adds UiAutomator 'drag' APIs to UiObject and UiDeviceAdam Momtaz
bug:7409880 Change-Id: I73e61d39f1c689ac8e376b9135ae8447c70cec56
2013-02-06Merge "instrumentation based UI Automator static library"Guang Zhu
2013-02-05instrumentation based UI Automator static libraryGuang Zhu
* further refactoring to split dependencies on public APIs * instrumentation base UI Automator test case base class still called UiAutomatorTestCase, for ease of transition * not all test runner features are ported over yet Bug: 8112323 Change-Id: Ibb4fc2c2164b59fb00b0b46c77118db788b10537
2013-02-05Merge "Handle multiple AccessibilityEvent parsing for scrolling"Adam Momtaz
2013-02-05Update for renamed APIsSvetoslav
Change-Id: I4703830d6554f16abfd03c2e162a317f278cc005
2013-02-05Handle multiple AccessibilityEvent parsing for scrollingAdam Momtaz
Refactored to handle Accessibility events into their corresponding Predicate types. Fixed scrollSwipe to allow it to receive all relevant accessibility events so to determine current scroll position. This required the reading the last scroll event from a list of events. bug:8099066 Change-Id: If1770b5fc7b56da03dd16ec3f8e5fe4686f7580b
2013-01-31New UiAutomator API Level 18Adam Momtaz
UiSelector.checkable bug:7622129 UiObject.getClassName bug:7622402 UiDevice.getDisplayRotation and isNaturalOrientation now wait for idle before executing. bug:7622137 Change-Id: Iddcbc3116241e3b7f1b68c4a5dda3346ad5d5871
2013-01-31Added resource id attribute to the uiautomatorviewerAdam Momtaz
Modified the UiSelector as well to support the naming convention used for the id. bug:8099047 Change-Id: I4f467d323492ff51e332ed69cc6a3b655c5700c8
2013-01-31Support for multipointer gesturesAdam Momtaz
Change-Id: I5e43e78c68bb24e8600864c318c737d3d1fca646
2013-01-31futher split of UI automator code base and refactoringGuang Zhu
* library/core-src should use only public framework APIs and be agnostic about shell based or instrumentation based test runner plumbings * Functions inside InteractionController that uses private APIs are now delegated through UiAutomatorBridge * ShellUiAutomatorBridge and OnDeviceUiAutomatorBridge are refactored accordingly to call WindowManager and PowerManager, and moved into shell specific and instrumentation specific locations accordingly Bug: 8112323 Change-Id: I79d8a0014e785af6d8d702473b1e568eeac6e652
2013-01-30split the code of test runner and core into separate sub foldersGuang Zhu
This will serve as the basis for further changes to use the core framework on top of alternative test runner. Change-Id: I389cbc8e79a004144c95bc99f7d2a58521541781