chromium/chrome/browser/ui/views/autofill/popup/popup_pixel_test.h

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef CHROME_BROWSER_UI_VIEWS_AUTOFILL_POPUP_POPUP_PIXEL_TEST_H_
#define CHROME_BROWSER_UI_VIEWS_AUTOFILL_POPUP_POPUP_PIXEL_TEST_H_

#include <concepts>
#include <string>
#include <tuple>

#include "base/i18n/rtl.h"
#include "base/memory/raw_ptr.h"
#include "base/strings/strcat.h"
#include "chrome/browser/ui/autofill/autofill_popup_view_delegate.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_window.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/browser/ui/test/test_browser_ui.h"
#include "chrome/browser/ui/views/autofill/popup/popup_base_view.h"
#include "chrome/test/base/in_process_browser_test.h"
#include "content/public/test/browser_test.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/base/ui_base_switches.h"

namespace autofill {

namespace {
NiceMock;
Return;
}  // namespace

TestParameterType;

// A base class to do pixel tests for classes that derive from `PopupBaseView`.
// By default, the test class has two parameters: Dark vs light mode and RTL vs
// LTR for the text direction of the browser language.
template <std::derived_from<PopupBaseView> View,
          std::derived_from<AutofillPopupViewDelegate> Controller,
          typename ParameterType = TestParameterType>
class PopupPixelTest : public UiBrowserTest,
                       public testing::WithParamInterface<ParameterType> {};

}  // namespace autofill

#endif  // CHROME_BROWSER_UI_VIEWS_AUTOFILL_POPUP_POPUP_PIXEL_TEST_H_