#include "mojo/public/cpp/system/data_pipe_producer.h"
#include <algorithm>
#include <limits>
#include <memory>
#include <string>
#include "base/containers/span.h"
#include "base/files/file.h"
#include "base/files/file_path.h"
#include "base/files/scoped_temp_dir.h"
#include "base/functional/bind.h"
#include "base/functional/callback.h"
#include "base/memory/raw_ptr.h"
#include "base/run_loop.h"
#include "base/strings/stringprintf.h"
#include "base/task/sequenced_task_runner.h"
#include "base/test/task_environment.h"
#include "mojo/public/cpp/system/data_pipe.h"
#include "mojo/public/cpp/system/file_data_source.h"
#include "mojo/public/cpp/system/filtered_data_source.h"
#include "mojo/public/cpp/system/simple_watcher.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace mojo {
namespace {
class DataPipeReader { … };
class DataPipeProducerTest : public testing::Test { … };
struct DataPipeObserverData { … };
class TestObserver : public FilteredDataSource::Filter { … };
TEST_F(DataPipeProducerTest, WriteFromFile) { … }
TEST_F(DataPipeProducerTest, WriteFromFilePartial) { … }
TEST_F(DataPipeProducerTest, WriteFromInvalidFile) { … }
TEST_F(DataPipeProducerTest, TinyFile) { … }
TEST_F(DataPipeProducerTest, HugeFile) { … }
TEST_F(DataPipeProducerTest, WriteLengthGreaterThanFile) { … }
}
}