1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Use of this source code is governed by a BSD-style license that can be 3 # found in the LICENSE file. 4 from telemetry import test 5 from telemetry.page import page_test 6 7 8 class PixelTestFailure(Exception): 9 pass 10 11 12 class PixelValidator(page_test.PageTest): 13 def __init__(self): 14 super(PixelValidator, self).__init__('ValidatePage') 15 16 def CustomizeBrowserOptions(self, options): 17 options.AppendExtraBrowserArg('--enable-webgl') 18 19 def ValidatePage(self, page, tab, results): 20 # TODO(bajones): Grab screenshot, compare to reference. 21 # page.reference_image 22 pass 23 24 25 class Pixel(test.Test): 26 enabled = False 27 test = PixelValidator 28 page_set = 'page_sets/pixel_tests.json' 29