chromium/components/paint_preview/common/file_stream_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.

#ifdef UNSAFE_BUFFERS_BUILD
// TODO(crbug.com/40285824): Remove this and convert code to safer constructs.
#pragma allow_unsafe_buffers
#endif

#include "components/paint_preview/common/file_stream.h"

#include "base/files/scoped_temp_dir.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace paint_preview {

// Test reading and writing from a file.
TEST(PaintPreviewFileStreamTest, TestWriteRead) {}

// Test writing failure.
TEST(PaintPreviewFileStreamTest, TestWriteFail) {}

// Test writing beyond max.
TEST(PaintPreviewFileStreamTest, TestWriteFailCapped) {}

// Test writing beyond max on first write.
TEST(PaintPreviewFileStreamTest, TestWriteFailCappedFirstWrite) {}

// Test writing beyond max (with overflow).
TEST(PaintPreviewFileStreamTest, TestWriteFailOverflow) {}

// Test reading to skip.
TEST(PaintPreviewFileStreamTest, TestSkip) {}

// Test read and skip.
TEST(PaintPreviewFileStreamTest, TestReadAndSkip) {}

// Test reading failure.
TEST(PaintPreviewFileStreamTest, TestReadFail) {}

}  // namespace paint_preview