blob: 3087564ff360b8ddb0ecce7677a6545569b1a763 [file] [log] [blame]
// Copyright 2018 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
package graphics
import (
func init() {
Func: ScreenshotChrome,
Desc: "Takes a screenshot using Chrome",
Contacts: []string{""},
Attr: []string{"group:mainline", "informational"},
SoftwareDeps: []string{"chrome"},
Fixture: "chromeGraphics",
func ScreenshotChrome(ctx context.Context, s *testing.State) {
cr := s.FixtValue().(*chrome.Chrome)
err := sshot.SShot(ctx, s, cr, func(ctx context.Context, path string) error {
return screenshot.CaptureChrome(ctx, cr, path)
if err != nil {
s.Fatal("Failure in screenshot comparison: ", err)