OSDN Git Service

Use StubProvider for functional tests.
authorSteve McKay <smckay@google.com>
Tue, 27 Oct 2015 00:03:55 +0000 (17:03 -0700)
committerSteve McKay <smckay@google.com>
Tue, 3 Nov 2015 21:18:00 +0000 (13:18 -0800)
commit0c3c695469715288568a514842b157c05df430a0
tree4d421df7ae623b64a15448dc4c8b62be1d3b4bf2
parentf789ef7e381ea57a4f515fde470d40f93bc5f345
Use StubProvider for functional tests.

Add a "UiBot" class for driving the UI from tests.
Add a "DocumentsProviderHelper" class for convenient test doc setup.
Update FilesActivityUiTest to use "TargetContext" which is
    necessary in order to perform ContentProvider
    operations.
Fix a bug where CopyTest relied on implicit order of roots.
Don't include guava in tests...since it breaks functional tests (incompatible class def).
Add test coverage for:
- basic roots list.
- basic files list.
- Live updates to files list.
- basic delete operations.

Bug: 24988170
Change-Id: I2ec01a5e1a474314cb33efb6e92df0f61dfcc1da
NOTE: This is currently broken at the point I try to init files in the stub roots.
packages/DocumentsUI/tests/Android.mk
packages/DocumentsUI/tests/src/com/android/documentsui/CopyTest.java
packages/DocumentsUI/tests/src/com/android/documentsui/DocumentsProviderHelper.java [new file with mode: 0644]
packages/DocumentsUI/tests/src/com/android/documentsui/FilesActivityUiTest.java
packages/DocumentsUI/tests/src/com/android/documentsui/StubProvider.java
packages/DocumentsUI/tests/src/com/android/documentsui/UiBot.java [new file with mode: 0644]