chromium/media/mojo/common/mojo_decoder_buffer_converter_unittest.cc

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

#include "media/mojo/common/mojo_decoder_buffer_converter.h"

#include <stdint.h>

#include <memory>

#include "base/run_loop.h"
#include "base/test/mock_callback.h"
#include "base/test/task_environment.h"
#include "media/base/decoder_buffer.h"
#include "media/base/decrypt_config.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace media {

namespace {

uint32_t kDefaultDataPipeCapacityBytes =;

MATCHER_P(MatchesDecoderBuffer, buffer, "") {}

class MojoDecoderBufferConverter {};

}  // namespace

TEST(MojoDecoderBufferConverterTest, ConvertDecoderBuffer_Normal) {}

TEST(MojoDecoderBufferConverterTest, ConvertDecoderBuffer_EOS) {}

// TODO(xhwang): Investigate whether we can get rid of zero-byte-buffer.
// See http://crbug.com/663438
TEST(MojoDecoderBufferConverterTest, ConvertDecoderBuffer_ZeroByteBuffer) {}

TEST(MojoDecoderBufferConverterTest, ConvertDecoderBuffer_KeyFrame) {}

TEST(MojoDecoderBufferConverterTest, ConvertDecoderBuffer_EncryptedBuffer) {}

// This test verifies that a DecoderBuffer larger than data-pipe capacity
// can be transmitted properly.
TEST(MojoDecoderBufferConverterTest, Chunked) {}

// This test verifies that MojoDecoderBufferReader::ReadCB is called with a
// NULL DecoderBuffer if data pipe is closed during transmission.
TEST(MojoDecoderBufferConverterTest, WriterSidePipeError) {}

// This test verifies that MojoDecoderBuffer supports concurrent writes and
// reads.
TEST(MojoDecoderBufferConverterTest, ConcurrentDecoderBuffers) {}

TEST(MojoDecoderBufferConverterTest, FlushWithoutRead) {}

TEST(MojoDecoderBufferConverterTest, FlushAfterRead) {}

TEST(MojoDecoderBufferConverterTest, FlushBeforeRead) {}

TEST(MojoDecoderBufferConverterTest, FlushBeforeChunkedRead) {}

TEST(MojoDecoderBufferConverterTest, FlushDuringChunkedRead) {}

TEST(MojoDecoderBufferConverterTest, FlushDuringConcurrentReads) {}

TEST(MojoDecoderBufferConverterTest, WriterWithInvalidHandle) {}

TEST(MojoDecoderBufferConverterTest, ReaderWithInvalidHandle) {}

}  // namespace media