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

Unified Diff: content/test/gpu/gpu_tests/gpu_rasterization.py

Issue 303113004: gpu testing: Handle non-integral device pixel ratio. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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
« no previous file with comments | « content/test/gpu/gpu_tests/cloud_storage_test_base.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/test/gpu/gpu_tests/gpu_rasterization.py
diff --git a/content/test/gpu/gpu_tests/gpu_rasterization.py b/content/test/gpu/gpu_tests/gpu_rasterization.py
index 4bcef4b347f6fad2d005842fafab2e78d9f04af4..90e9c2c1f6719d8e5dd6a158102ed1d85b6d4121 100644
--- a/content/test/gpu/gpu_tests/gpu_rasterization.py
+++ b/content/test/gpu/gpu_tests/gpu_rasterization.py
@@ -49,7 +49,7 @@ class _GpuRasterizationValidator(cloud_storage_test_base.ValidatorBase):
device_pixel_ratio = tab.EvaluateJavaScript('window.devicePixelRatio')
if hasattr(page, 'test_rect'):
- test_rect = [x * device_pixel_ratio for x in page.test_rect]
+ test_rect = [int(x * device_pixel_ratio) for x in page.test_rect]
screenshot = screenshot.Crop(
test_rect[0], test_rect[1],
test_rect[2], test_rect[3])
« no previous file with comments | « content/test/gpu/gpu_tests/cloud_storage_test_base.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698