#include <optional>
#include <string_view>
#include "base/base64.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
#include "base/functional/bind.h"
#include "base/run_loop.h"
#include "base/strings/utf_string_conversions.h"
#include "base/unguessable_token.h"
#include "build/build_config.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/test/base/in_process_browser_test.h"
#include "chrome/test/base/ui_test_utils.h"
#include "components/paint_preview/browser/paint_preview_client.h"
#include "components/paint_preview/common/file_stream.h"
#include "components/paint_preview/common/mojom/paint_preview_recorder.mojom-shared.h"
#include "components/paint_preview/common/proto/paint_preview.pb.h"
#include "components/paint_preview/common/recording_map.h"
#include "components/paint_preview/common/serialized_recording.h"
#include "components/paint_preview/common/test_utils.h"
#include "components/ukm/test_ukm_recorder.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/common/content_switches.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
#include "content/public/test/fenced_frame_test_util.h"
#include "net/dns/mock_host_resolver.h"
#include "net/test/embedded_test_server/embedded_test_server.h"
#include "services/metrics/public/cpp/ukm_builders.h"
#include "third_party/blink/public/common/associated_interfaces/associated_interface_provider.h"
#include "third_party/skia/include/core/SkPicture.h"
#include "third_party/skia/include/core/SkStream.h"
#include "url/gurl.h"
namespace paint_preview {
class NoOpPaintPreviewRecorder : public mojom::PaintPreviewRecorder { … };
class PaintPreviewBrowserTest
: public InProcessBrowserTest,
public testing::WithParamInterface<RecordingPersistence> { … };
IN_PROC_BROWSER_TEST_P(PaintPreviewBrowserTest, CaptureFrame) { … }
IN_PROC_BROWSER_TEST_P(PaintPreviewBrowserTest,
CaptureMainFrameWithCrossProcessSubframe) { … }
class PaintPreviewFencedFrameBrowserTest : public PaintPreviewBrowserTest { … };
IN_PROC_BROWSER_TEST_P(PaintPreviewFencedFrameBrowserTest,
CaptureMainFrameWithCrossProcessFencedFrames) { … }
IN_PROC_BROWSER_TEST_P(PaintPreviewFencedFrameBrowserTest,
DoNotAffectAnotherFrameWhenRemovingFencedFrame) { … }
IN_PROC_BROWSER_TEST_P(PaintPreviewBrowserTest,
CaptureMainFrameWithScrollableSameProcessSubframe) { … }
IN_PROC_BROWSER_TEST_P(PaintPreviewBrowserTest,
CaptureMainFrameWithNonScrollableSameProcessSubframe) { … }
IN_PROC_BROWSER_TEST_P(PaintPreviewBrowserTest, DontReloadInRenderProcessExit) { … }
INSTANTIATE_TEST_SUITE_P(…);
INSTANTIATE_TEST_SUITE_P(…);
}