chromium/chrome/browser/media/router/providers/cast/cast_session_client_unittest.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/media/router/providers/cast/cast_session_client.h"

#include <memory>
#include <tuple>
#include <utility>

#include "base/functional/bind.h"
#include "base/logging.h"
#include "base/run_loop.h"
#include "base/test/mock_log.h"
#include "base/test/values_test_util.h"
#include "chrome/browser/media/router/providers/cast/cast_activity_manager.h"
#include "chrome/browser/media/router/providers/cast/cast_internal_message_util.h"
#include "chrome/browser/media/router/providers/cast/cast_session_client_impl.h"
#include "chrome/browser/media/router/providers/cast/mock_app_activity.h"
#include "chrome/browser/media/router/providers/cast/test_util.h"
#include "chrome/browser/media/router/test/mock_mojo_media_router.h"
#include "chrome/browser/media/router/test/provider_test_helpers.h"
#include "components/media_router/common/providers/cast/channel/cast_test_util.h"
#include "components/media_router/common/test/test_helper.h"
#include "content/public/browser/browser_task_traits.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/test/browser_task_environment.h"
#include "mojo/public/cpp/bindings/receiver.h"
#include "services/data_decoder/public/cpp/test_support/in_process_data_decoder.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"

IsJson;
ParseJsonDict;
PresentationConnectionCloseReason;
_;
AllOf;
AnyNumber;
HasSubstr;
IsEmpty;
NiceMock;
Not;
Return;
WithArg;

namespace media_router {

namespace {
constexpr int kTabId =;

class MockPresentationConnection : public blink::mojom::PresentationConnection {};

}  // namespace

#define EXPECT_ERROR_LOG(matcher)

class CastSessionClientImplTest : public testing::Test {};

TEST_F(CastSessionClientImplTest, OnInvalidJson) {}

TEST_F(CastSessionClientImplTest, OnInvalidMessage) {}

TEST_F(CastSessionClientImplTest, OnMessageWrongClientId) {}

TEST_F(CastSessionClientImplTest, OnMessageWrongSessionId) {}

TEST_F(CastSessionClientImplTest, NullFieldsAreRemoved) {}

TEST_F(CastSessionClientImplTest, AppMessageFromClient) {}

TEST_F(CastSessionClientImplTest, OnMediaStatusUpdatedWithPendingRequest) {}

TEST_F(CastSessionClientImplTest, SendSetVolumeCommandToReceiver) {}

TEST_F(CastSessionClientImplTest, SendStopSessionCommandToReceiver) {}

TEST_F(CastSessionClientImplTest, CloseConnection) {}

TEST_F(CastSessionClientImplTest, DidCloseConnection) {}

}  // namespace media_router