Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1078)

Issue 420013002: Introduce NON_ZERO_DURATION for animation unit tests (Closed)

Created:
6 years, 5 months ago by James Cook
Modified:
6 years, 4 months ago
Reviewers:
ajuma, oshima, sky
CC:
chromium-reviews, sadrul, yusukes+watch_chromium.org, sievers+watch_chromium.org, yukishiino+watch_chromium.org, ben+aura_chromium.org, tdanderson+views_chromium.org, jam, jbauman+watch_chromium.org, nona+watch_chromium.org, darin-cc_chromium.org, timurrrr+watch_chromium.org, kalyank, bruening+watch_chromium.org, tdanderson+overview_chromium.org, penghuang+watch_chromium.org, piman+watch_chromium.org, ben+views_chromium.org, Ian Vollick, tfarina, danakj+watch_chromium.org, James Su, glider+watch_chromium.org, ben+ash_chromium.org
Project:
chromium
Visibility:
Public.

Description

Introduce NON_ZERO_DURATION for animation unit tests Animations are usually disabled in unit tests for performance. However, to test the animation system itself some tests request "normal" durations. Under some conditions (remote desktop, animation disabled for accessibility) the "normal" duration could still be zero. This was causing test failures and use-after-frees in ash_unittests on the drmemory bots and for developers using remote desktop. Introduce NON_ZERO_DURATION to signal that animation must be enabled and the duration must be non-zero, but other than that can be as short as possible. BUG=397478, 396969 TEST=ash_unittests on drmemory, Windows and Chrome OS bots Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=286089

Patch Set 1 #

Total comments: 2

Patch Set 2 : multiplier/divisor #

Total comments: 2

Patch Set 3 : LayerAnimatorTest #

Patch Set 4 : rebase #

Total comments: 1

Patch Set 5 : non-zero-duration #

Patch Set 6 : rebase #

Patch Set 7 : content_unittests #

Unified diffs Side-by-side diffs Delta from patch set Stats (+76 lines, -74 lines) Patch
M ash/desktop_background/desktop_background_controller_unittest.cc View 1 2 3 4 4 chunks +8 lines, -7 lines 0 comments Download
M ash/shelf/shelf_layout_manager_unittest.cc View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M ash/wm/overview/window_selector_unittest.cc View 1 2 3 4 5 2 chunks +6 lines, -6 lines 0 comments Download
M ash/wm/window_animations_unittest.cc View 1 2 3 4 3 chunks +7 lines, -4 lines 0 comments Download
M ash/wm/workspace_controller_unittest.cc View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M content/browser/web_contents/aura/window_slider_unittest.cc View 1 2 3 4 5 6 1 chunk +2 lines, -1 line 0 comments Download
M tools/valgrind/drmemory/suppressions.txt View 1 chunk +0 lines, -18 lines 0 comments Download
M tools/valgrind/gtest_exclude/ash_unittests.gtest-drmemory_win32.txt View 1 chunk +0 lines, -6 lines 0 comments Download
M ui/aura/window_unittest.cc View 1 2 3 4 5 5 chunks +10 lines, -10 lines 0 comments Download
M ui/compositor/layer_animation_element.cc View 1 2 3 4 2 chunks +9 lines, -7 lines 0 comments Download
M ui/compositor/layer_animator_unittest.cc View 1 2 3 4 1 chunk +2 lines, -2 lines 0 comments Download
M ui/compositor/scoped_animation_duration_scale_mode.h View 1 2 3 4 1 chunk +4 lines, -0 lines 0 comments Download
M ui/keyboard/keyboard_controller_unittest.cc View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M ui/views/controls/textfield/textfield.cc View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M ui/views/widget/widget_unittest.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M ui/wm/core/visibility_controller_unittest.cc View 1 2 3 4 1 chunk +2 lines, -2 lines 0 comments Download
M ui/wm/core/window_animations.cc View 1 2 3 4 2 chunks +18 lines, -4 lines 0 comments Download

Messages

Total messages: 20 (0 generated)
James Cook
oshima, PTAL
6 years, 5 months ago (2014-07-26 00:28:25 UTC) #1
oshima
nice! lgtm with one suggestion. https://codereview.chromium.org/420013002/diff/1/ui/compositor/layer_animation_element.cc File ui/compositor/layer_animation_element.cc (right): https://codereview.chromium.org/420013002/diff/1/ui/compositor/layer_animation_element.cc#newcode28 ui/compositor/layer_animation_element.cc:28: const int kTestDurationScaleFactor = ...
6 years, 5 months ago (2014-07-26 00:53:26 UTC) #2
James Cook
ajuma, PTAL for ui/compositor and animation code. https://codereview.chromium.org/420013002/diff/1/ui/compositor/layer_animation_element.cc File ui/compositor/layer_animation_element.cc (right): https://codereview.chromium.org/420013002/diff/1/ui/compositor/layer_animation_element.cc#newcode28 ui/compositor/layer_animation_element.cc:28: const int ...
6 years, 5 months ago (2014-07-26 04:02:32 UTC) #3
ajuma
lgtm with one nit: https://codereview.chromium.org/420013002/diff/20001/ui/compositor/layer_animator_unittest.cc File ui/compositor/layer_animator_unittest.cc (right): https://codereview.chromium.org/420013002/diff/20001/ui/compositor/layer_animator_unittest.cc#newcode1894 ui/compositor/layer_animator_unittest.cc:1894: ScopedAnimationDurationScaleMode::TEST_DURATION); The rest of the ...
6 years, 5 months ago (2014-07-26 14:34:19 UTC) #4
James Cook
sky, can I get OWNERS for ui/* ? https://codereview.chromium.org/420013002/diff/20001/ui/compositor/layer_animator_unittest.cc File ui/compositor/layer_animator_unittest.cc (right): https://codereview.chromium.org/420013002/diff/20001/ui/compositor/layer_animator_unittest.cc#newcode1894 ui/compositor/layer_animator_unittest.cc:1894: ScopedAnimationDurationScaleMode::TEST_DURATION); ...
6 years, 4 months ago (2014-07-28 04:42:35 UTC) #5
sky
https://codereview.chromium.org/420013002/diff/60001/ui/compositor/scoped_animation_duration_scale_mode.h File ui/compositor/scoped_animation_duration_scale_mode.h (right): https://codereview.chromium.org/420013002/diff/60001/ui/compositor/scoped_animation_duration_scale_mode.h#newcode22 ui/compositor/scoped_animation_duration_scale_mode.h:22: TEST_DURATION, I'm concerned that naming this 'test' implies anyone ...
6 years, 4 months ago (2014-07-28 15:35:09 UTC) #6
James Cook
sky PTAL - How about "non-zero duration" along with the comment about how it's different ...
6 years, 4 months ago (2014-07-28 15:47:32 UTC) #7
sky
LGTM
6 years, 4 months ago (2014-07-28 15:57:20 UTC) #8
James Cook
The CQ bit was checked by jamescook@chromium.org
6 years, 4 months ago (2014-07-28 16:04:40 UTC) #9
James Cook
The CQ bit was unchecked by jamescook@chromium.org
6 years, 4 months ago (2014-07-28 16:04:49 UTC) #10
James Cook
The CQ bit was checked by jamescook@chromium.org
6 years, 4 months ago (2014-07-28 16:05:32 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jamescook@chromium.org/420013002/100001
6 years, 4 months ago (2014-07-28 16:06:44 UTC) #12
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_chromium_chromeos_rel on tryserver.chromium.linux ...
6 years, 4 months ago (2014-07-28 20:37:05 UTC) #13
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-07-28 21:12:52 UTC) #14
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_swarming on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_swarming/builds/553)
6 years, 4 months ago (2014-07-28 21:12:53 UTC) #15
James Cook
The CQ bit was checked by jamescook@chromium.org
6 years, 4 months ago (2014-07-29 00:11:37 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jamescook@chromium.org/420013002/120001
6 years, 4 months ago (2014-07-29 00:13:26 UTC) #17
commit-bot: I haz the power
Change committed as 286089
6 years, 4 months ago (2014-07-29 04:22:13 UTC) #18
James Cook
A revert of this CL has been created in https://codereview.chromium.org/413403011/ by jamescook@chromium.org. The reason for ...
6 years, 4 months ago (2014-07-29 05:02:48 UTC) #19
Peter Mayo
6 years, 4 months ago (2014-07-29 21:44:31 UTC) #20
Message was sent while issue was closed.
On 2014/07/29 05:02:48, James Cook wrote:
> A revert of this CL has been created in
> https://codereview.chromium.org/413403011/ by mailto:jamescook@chromium.org.
> 
> The reason for reverting is: I suspect this is causing Linux Tests dbg (2)
> failures in app_list_unittests:
>
http://build.chromium.org/p/chromium.linux/builders/Linux%20Tests%20%28dbg%29...
> 
> Strangely I had green try runs for linux_chromium_rel for app_list_unittests.
> .

I believe, having tried to reproduce the failure and failed, that the failure
was flake of an unknown origin.

The landed revision in the tree looked good to me.

Powered by Google App Engine
This is Rietveld 408576698