chromium/chrome/test/data/webui/side_panel/read_anything/read_anything_browsertest.cc

// 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.

#include "base/run_loop.h"
#include "base/test/scoped_feature_list.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_window/public/browser_window_features.h"
#include "chrome/browser/ui/views/side_panel/side_panel_entry_id.h"
#include "chrome/browser/ui/views/side_panel/side_panel_ui.h"
#include "chrome/common/webui_url_constants.h"
#include "chrome/test/base/web_ui_mocha_browser_test.h"
#include "content/public/common/url_constants.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
#include "ui/accessibility/accessibility_features.h"

class ReadAnythingMochaBrowserTest : public WebUIMochaBrowserTest {};

ReadAnythingMochaTest;

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, CheckmarkVisibleOnSelected) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, Common) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, Logger) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, LoadingScreen) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, VoiceSelectionMenu) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, VoiceLanguageUtil) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, ReadAloudFlag) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, FontSize) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, FontMenu) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, ColorMenu) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, LetterSpacing) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, LineSpacing) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, Toolbar) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, UpdateContent) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, AppReceivesToolbarChanges) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, AppStyleUpdater) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, LanguageMenu) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, LinksToggle) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, PlayPause) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, HighlightToggle) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, NextPrevious) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, RateSelection) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, FakeTreeBuilderTest) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest,
                       UpdateContentSelectionWithHighlights) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, LanguageChanged) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, VoiceSelection) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, Prefs) {}

#if BUILDFLAG(IS_CHROMEOS_LACROS)
#define MAYBE_UpdateVoicePack
#else
#define MAYBE_UpdateVoicePack
#endif
IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, MAYBE_UpdateVoicePack) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingMochaTest, ToolbarOverflow) {}

// Integration tests that need the actual Read Aloud flag enabled because they
// use the full C++ pipeline
class ReadAnythingReadAloudMochaTest : public ReadAnythingMochaBrowserTest {};

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest,
                       LinksToggledIntegration) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest,
                       SpeechUsesMaxTextLength) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest,
                       ReadAloud_UpdateContentSelection) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest,
                       ReadAloud_UpdateContentSelectionPDF) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest, ReadAloudHighlight) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest,
                       WordBoundariesUsedForSpeech) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest, Speech) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest, UpdateContentSelection) {}

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudMochaTest,
                       UpdateContentIntegration) {}

// Integration tests that need the actual Read Aloud flag enabled and the word
// highlighting flag because they use the full C++ pipeline
class ReadAnythingReadAloudWordHighlightingMochaTest
    : public ReadAnythingMochaBrowserTest {};

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudWordHighlightingMochaTest,
                       WordHighlighting) {}

// TODO(b/301131238): Remove this test once the word highlighting flag is
// removed.
// Integration tests that need the actual Read Aloud flag enabled and the word
// highlighting flag because they use the full C++ pipeline
class ReadAnythingReadAloudWordHighlightingDisabledMochaTest
    : public ReadAnythingMochaBrowserTest {};

IN_PROC_BROWSER_TEST_F(ReadAnythingReadAloudWordHighlightingDisabledMochaTest,
                       WordHighlighting) {}