chromium/third_party/blink/renderer/modules/video_rvfc/video_frame_callback_requester_impl_test.cc

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

#include "third_party/blink/renderer/modules/video_rvfc/video_frame_callback_requester_impl.h"
#include "base/memory/raw_ptr.h"
#include "base/memory/raw_ref.h"
#include "third_party/blink/renderer/core/page/page_animator.h"

#include "base/time/time.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/bindings/core/v8/script_function.h"
#include "third_party/blink/renderer/bindings/core/v8/v8_binding_for_testing.h"
#include "third_party/blink/renderer/core/dom/scripted_animation_controller.h"
#include "third_party/blink/renderer/core/html/media/html_media_test_helper.h"
#include "third_party/blink/renderer/core/html/media/html_video_element.h"
#include "third_party/blink/renderer/core/loader/empty_clients.h"
#include "third_party/blink/renderer/core/testing/page_test_base.h"
#include "third_party/blink/renderer/core/timing/performance.h"
#include "third_party/blink/renderer/platform/testing/empty_web_media_player.h"
#include "third_party/blink/renderer/platform/testing/unit_test_helpers.h"

_;
ByMove;
Invoke;
Return;

namespace blink {

VideoFramePresentationMetadata;

namespace {

class MockWebMediaPlayer : public EmptyWebMediaPlayer {};

class MockFunction : public ScriptFunction::Callable {};

// Helper class to wrap a VideoFramePresentationData, which can't have a copy
// constructor, due to it having a media::VideoFrameMetadata instance.
class MetadataHelper {};

VideoFramePresentationMetadata MetadataHelper::metadata_;

// Helper class that compares the parameters used when invoking a callback, with
// the reference parameters we expect.
class VfcRequesterParameterVerifierCallback
    : public VideoFrameRequestCallbackCollection::VideoFrameCallback {};

}  // namespace

class VideoFrameCallbackRequesterImplTest : public PageTestBase {};

class VideoFrameCallbackRequesterImplNullMediaPlayerTest
    : public VideoFrameCallbackRequesterImplTest {};

TEST_F(VideoFrameCallbackRequesterImplTest, VerifyRequestVideoFrameCallback) {}

TEST_F(VideoFrameCallbackRequesterImplTest,
       VerifyCancelVideoFrameCallback_BeforePresentedFrame) {}

TEST_F(VideoFrameCallbackRequesterImplTest,
       VerifyCancelVideoFrameCallback_AfterPresentedFrame) {}

TEST_F(VideoFrameCallbackRequesterImplTest,
       VerifyClearedMediaPlayerCancelsPendingExecution) {}

TEST_F(VideoFrameCallbackRequesterImplTest, VerifyParameters_WindowRaf) {}

TEST_F(VideoFrameCallbackRequesterImplTest, OnXrFrameData) {}

TEST_F(VideoFrameCallbackRequesterImplNullMediaPlayerTest, VerifyNoCrash) {}

}  // namespace blink