| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Implements a local binder and #onBind in the service to return the
service instance.
- Mocks BugreportManager in the service to avoid service interacting
with the dumpstate.
- Fixes dialog name field did not disable after service is finished.
- Fixes screenshot did not remove if the name is empty.
- Extends screenshot delay timeout in tests.
- Fine tune the UiBot to fit new bugreport notification.
- Removes obsolete cases in the tests.
Bug: 143130523
Test: atest BugreportReceiverTest
Change-Id: Iae89206da1d08a10891503869bbbf1ce18d4e31f
|
| |
|
|
|
|
|
|
| |
BUG: 30639703
Test: mmm -j32 frameworks/base/packages/Shell && adb install -r -g ${ANDROID_PRODUCT_OUT}/data/app/ShellTests/ShellTests.apk && adb shell am instrument -e class com.android.shell.BugreportReceiverTest -w com.android.shell.tests/android.support.test.runner.AndroidJUnitRunner
Change-Id: I2635439ac0c033d1ad6b4ba545b8d751f5576b72
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- testProgress_changeJustDetailsTouchingNotification was failing because
the notification mechanism changed and now provides a way to expand
and collapse the actions bar, and the test was collapsing it instead
of opening the details dialog. It was fixed by tapping the
notification content instead of the notification title.
- Similarly, openProgressNotification() was refactored to use the
bugreport name instead of id.
- Uses getObject() (instead of getVisibleObject()) to get the activity
from the intent chooser.
- Removed the redundant call to back to dismiss the keyboard, which was
causing some tests to fail due to an accessibility bug.
- Retry a few times in case the bugreport name system property assertion
fails, since the property is set by a background thread.
- Improved how notifications are canceled.
- Created a sleep() helper.
Besides the test case improvements, it also removed a redundant call to
setCancelable() in the main code.
BUG: 30641229
BUG: 30639703
Change-Id: Icd79fada22d0b8e4be034068c3e9143ef0134eed
|
| |
|
|
|
|
|
|
|
| |
When using startActivity(intent), the platform allows the user to pick
the same activity for the intent, which can be a problem for sharing bug
reports when the device has personal and work profiles.
Change-Id: I1fd66905feb5d894307bbe5656c2aec705a59ab7
Fixes: 22115530
|
| |
|
|
|
| |
BUG: 30158896
Change-Id: I0eab22586f6b431f2abe837088d48a655e03d213
|
| |
|
|
|
|
|
|
|
| |
When tests run for the first time, the list of activities that can
handle ACTION_SEND_MULTIPLE might not be scrollable, which was cause the
scrollForward() method to fail.
BUG: 27431998
Change-Id: I5992bc9fec6291c74c4af7887ee66eb4f96e87c0
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When dumpstate starts, it estimates its maximum duration and sends it
through an extra on BUGREPORT_STARTED; as it progress, it sets a system
property with its current progress and if the progress value overflows
the estimated max, it increases the max as well.
Shell uses the max/progress to display the progress % in the
system notification, and need to handle the scenario where the max
changes. The initial implementation would recalculate the progress, with
makes it swing back and forth as dumpstate increases the max.
This CL changes the Shell logic so the progress never go back, just
forward. The drawback of this approach is that if dumpstate
underestimate the maximum, the progress might get stuck in a high
value (99%) early on, but such issue will be addressed in the long
term by tuning the estimated max value.
BUG: 26354314
Change-Id: I3a5416acaffaaa43fd28d2f1f8ec8ea12aa0d91e
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The "bugreport in progress" notification now have a "DETAILS" button
that when clicked opens a dialog window displaying the following fields:
- Name: short name for the bugreport, will be used as part of the
final files (and by default is the timestamp sent by dumpstate)
- Title: a 1-line title for the bugreport, will be used as the subject
in the final message.
- Description: a detailed description for the bug.
The main advantage of such dialog is that it allows users to enter more
info about a bugreport while it's being generated, rather then when the
bugreport is finished (since of the user doesn't remember what the
context was when the problem happened).
BUG: 25794470
BUG: 10676443
Change-Id: I0d1dba2a94ad989e541415a2a59475619a2e3d13
|
| |
|
|
|
|
|
|
| |
When ActionSendMultipleConsumerActivity is not the default action, it
just need to be selected, without clicking 'Just Once'
BUG: 25752530
Change-Id: I111063aa0dbba37e0cac8f0572f43a48c659e975
|
| |
|
|
|
|
|
| |
This check will make it easier to refactor how the bugreport is shared, which is a requirement for showing the bugreport details window.
BUG: 25794470
Change-Id: If29f0515586c6680a44e0d52c4fc587808e668aa
|
| |
|
|
|
|
|
|
| |
- Decrease delay by first checking if the activity is the default
selection.
- Handle scrolling so it won't fail if the activity is not visible.
Change-Id: I8fce920bad207c3f35375316a139f20c1dcb9343
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The old workflow was:
1. dumpstate starts.
2. When dumpstate finishes, it sends a BUGREPORT_FINISHED intent.
3. Shell's BugreportReceiver receives the BUGREPORT_FINISHED and issues a
system notification so user can share the bug report.
The new workflow is:
1. When dumpstate starts, it sends a BUGREPORT_STARTED with its pid and
the estimated total effort.
2. When Shell's BugreportReceiver receives the BUGREPORT_STARTED, it:
2.1 Issues a system notification so user can watch the
progresss (which is 0% initially).
2.2 Starts a service (BugreportProgressService) responsible for
polling the dumpstate progress (using system properties and the
pid) and updating the system notification.
3. As dumpstate progress, it updates the proper system property.
4. When dumpstate finishes, it sends a BUGREPORT_FINISHED event.
5. When Shell's BugreportReceiver receives the BUGREPORT_FINISHED, it:
5.1 Finishes the service if necessary.
5.2 Issues a system notification so user can share the bug report.
This CL handles the Shell changes only, the dumpstate changes will be
changed in a separate CL.
BUG: 25794470
Change-Id: Icbd0b42dd48e8db376b60544348b6818c6374338
|
|
|
These tests rely in the UI Automator to interact with the UI and
follow the workflow below:
* creates the bug report files
* generates the BUGREPORT_FINISHED intent
* emulate user actions to share the intent with a custom activity
* asserts the extras received by the custom activity
It still have some limitations, like requiring the phone to be unlocked
and having the bugreport warning already checked, and those will be
addressed in future CLs.
BUG: 25752530
Change-Id: I01d7fad9f94daf156b728cbb9ef228bbfa6ee0f5
|