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

Unified Diff: tools/telemetry/telemetry/core/tab_unittest.py

Issue 23694031: Fix race conditions in window snapshot code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressing further feedback, added stress test for snapshots Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/telemetry/telemetry/core/tab_unittest.py
diff --git a/tools/telemetry/telemetry/core/tab_unittest.py b/tools/telemetry/telemetry/core/tab_unittest.py
index f555dc2812745a06c927cc1517a102b31bfcc07b..2258e76960a288b66b2ca5eb2ee2462a82b90156 100644
--- a/tools/telemetry/telemetry/core/tab_unittest.py
+++ b/tools/telemetry/telemetry/core/tab_unittest.py
@@ -3,12 +3,10 @@
# found in the LICENSE file.
import logging
-import time
from telemetry.core import util
from telemetry.core import exceptions
from telemetry.unittest import tab_test_case
-from telemetry.unittest import DisabledTest
def _IsDocumentVisible(tab):
@@ -56,7 +54,6 @@ class GpuTabTest(tab_test_case.TabTestCase):
self._extra_browser_args = ['--enable-gpu-benchmarking']
super(GpuTabTest, self).setUp()
- @DisabledTest
def testScreenshot(self):
if not self._tab.screenshot_supported:
logging.warning('Browser does not support screenshots, skipping test.')
@@ -68,8 +65,6 @@ class GpuTabTest(tab_test_case.TabTestCase):
self._tab.WaitForDocumentReadyStateToBeComplete()
pixel_ratio = self._tab.EvaluateJavaScript('window.devicePixelRatio || 1')
- # TODO(bajones): Sleep for a bit to counter BUG 260878.
- time.sleep(0.5)
screenshot = self._tab.Screenshot(5)
assert screenshot
screenshot.GetPixelColor(0 * pixel_ratio, 0 * pixel_ratio).AssertIsRGB(

Powered by Google App Engine
This is Rietveld 408576698