New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 781357 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2017
Cc:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

Incremental Junit4 instrumentation tests use stale test list

Project Member Reported by agrieve@chromium.org, Nov 3 2017

Issue description

To repro:
ninja -C out/Debug chrome_public_test_apk_incremental
out/Debug/bin/run_chrome_public_test_apk_incremental -f "*CompositorVisibilityTest. testSetVisibilityHidesSurfaces" -d 00b424b27f9028b4
# Rename testSetVisibilityHidesSurfaces-> testDog
ninja -C out/Debug chrome_public_test_apk_incremental
out/Debug/bin/run_chrome_public_test_apk_incremental -f "*CompositorVisibilityTest. testSetVisibilityHidesSurfaces" -d 00b424b27f9028b4


Still tries to run testSetVisibilityHidesSurfaces.


Looks like the issue is that the test list is cached here:
https://cs.chromium.org/chromium/src/build/android/pylib/local/device/local_device_instrumentation_test_run.py?rcl=a9ba8220705d3128a4f1c9b34335dc01a1b73801&l=602

And is only invalidate when the .apk's mtime changes. For incremental apks, the apk mtime rarely changes.
 
Looks like if you rename a test a recompile, options for timestamps that change:

test.lib.java/ChromePublicTest.jar (dist jar)
obj/chrome/android/chrome_public_test_apk_incremental.stamp

Project Member

Comment 2 by bugdroid1@chromium.org, Nov 8 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/293209f8d033161f4afafc504bd15d0b631167d8

commit 293209f8d033161f4afafc504bd15d0b631167d8
Author: Andrew Grieve <agrieve@chromium.org>
Date: Wed Nov 08 20:48:54 2017

Android: Invalidate test list cache properly for incremental test apks

Fixes test runner not noticing when you add / remove / rename tests.

Bug:  781357 
Change-Id: I1f8b1d78670ee337277dac0a55fbc3e4fd1be879
Reviewed-on: https://chromium-review.googlesource.com/755854
Commit-Queue: agrieve <agrieve@chromium.org>
Reviewed-by: John Budorick <jbudorick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#514929}
[modify] https://crrev.com/293209f8d033161f4afafc504bd15d0b631167d8/build/android/pylib/instrumentation/instrumentation_test_instance.py
[modify] https://crrev.com/293209f8d033161f4afafc504bd15d0b631167d8/build/android/pylib/local/device/local_device_instrumentation_test_run.py

Status: Fixed (was: Started)

Sign in to add a comment