chromium/chrome/browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_test_helper.cc

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

#include "chrome/browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_test_helper.h"

#include <string_view>

#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
#include "base/notreached.h"
#include "base/run_loop.h"
#include "base/strings/utf_string_conversions.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/views/frame/browser_non_client_frame_view.h"
#include "chrome/browser/ui/views/frame/browser_view.h"
#include "chrome/browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_view.h"
#include "chrome/browser/ui/views/web_apps/frame_toolbar/web_app_origin_text.h"
#include "chrome/browser/ui/views/web_apps/frame_toolbar/web_app_toolbar_button_container.h"
#include "chrome/browser/ui/web_applications/test/web_app_browsertest_util.h"
#include "chrome/browser/web_applications/mojom/user_display_mode.mojom.h"
#include "chrome/browser/web_applications/test/web_app_install_test_utils.h"
#include "chrome/browser/web_applications/web_app_constants.h"
#include "chrome/browser/web_applications/web_app_install_info.h"
#include "chrome/test/base/ui_test_utils.h"
#include "components/permissions/permission_request_manager.h"
#include "content/public/browser/web_contents.h"
#include "content/public/test/browser_test_utils.h"
#include "content/public/test/test_navigation_observer.h"
#include "net/test/embedded_test_server/embedded_test_server.h"
#include "ui/base/hit_test.h"
#include "ui/views/widget/widget.h"
#include "ui/views/window/non_client_view.h"
#include "url/gurl.h"

WebAppFrameToolbarTestHelper::WebAppFrameToolbarTestHelper() {}

WebAppFrameToolbarTestHelper::~WebAppFrameToolbarTestHelper() = default;

webapps::AppId WebAppFrameToolbarTestHelper::InstallWebApp(
    Profile* profile,
    const GURL& start_url) {}

webapps::AppId WebAppFrameToolbarTestHelper::InstallAndLaunchWebApp(
    Profile* profile,
    const GURL& start_url) {}

webapps::AppId WebAppFrameToolbarTestHelper::InstallAndLaunchWebApp(
    Browser* browser,
    const GURL& start_url) {}

webapps::AppId WebAppFrameToolbarTestHelper::InstallAndLaunchCustomWebApp(
    Browser* browser,
    std::unique_ptr<web_app::WebAppInstallInfo> web_app_info,
    const GURL& start_url) {}

GURL WebAppFrameToolbarTestHelper::
    LoadWindowControlsOverlayTestPageWithDataAndGetURL(
        net::test_server::EmbeddedTestServer* embedded_test_server,
        base::ScopedTempDir* temp_dir) {}

GURL WebAppFrameToolbarTestHelper::
    LoadWholeAppIsDraggableTestPageWithDataAndGetURL(
        net::test_server::EmbeddedTestServer* embedded_test_server,
        base::ScopedTempDir* temp_dir) {}

GURL WebAppFrameToolbarTestHelper::LoadTestPageWithDataAndGetURL(
    net::test_server::EmbeddedTestServer* embedded_test_server,
    base::ScopedTempDir* temp_dir,
    std::string_view test_html) {}

base::Value::List WebAppFrameToolbarTestHelper::GetXYWidthHeightListValue(
    content::WebContents* web_contents,
    const std::string& rect_value_list,
    const std::string& rect_var_name) {}

gfx::Rect WebAppFrameToolbarTestHelper::GetXYWidthHeightRect(
    content::WebContents* web_contents,
    const std::string& rect_value_list,
    const std::string& rect_var_name) {}

void WebAppFrameToolbarTestHelper::SetupGeometryChangeCallback(
    content::WebContents* web_contents) {}

// TODO(crbug.com/40809857): Flaky.
void WebAppFrameToolbarTestHelper::TestDraggableRegions() {}

BrowserView* WebAppFrameToolbarTestHelper::OpenPopup(
    const std::string& window_open_script) {}

void WebAppFrameToolbarTestHelper::GrantWindowManagementPermission(
    content::WebContents* web_contents) {}

void WebAppFrameToolbarTestHelper::GrantWindowManagementPermission() {}

WebAppOriginText* WebAppFrameToolbarTestHelper::origin_text_view() {}

void WebAppFrameToolbarTestHelper::SetOriginTextLabelForTesting(
    const std::u16string label_text) {}