diff options
author | Lucas CHOLLET <lucas.chollet@free.fr> | 2023-05-03 18:45:18 -0400 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2023-05-09 11:18:46 +0200 |
commit | 8c34959b53b2b72122fe6d2718d5dc060ff56875 (patch) | |
tree | 8e88ecd303fddce25ffc170d297bc76762f115da /Tests/LibCore | |
parent | 48b000a36cb22550e2c5314bc6c471812c963d0c (diff) | |
download | serenity-8c34959b53b2b72122fe6d2718d5dc060ff56875.zip |
AK: Add the `Input` word to input-only buffered streams
This concerns both `BufferedSeekable` and `BufferedFile`.
Diffstat (limited to 'Tests/LibCore')
-rw-r--r-- | Tests/LibCore/TestLibCoreStream.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Tests/LibCore/TestLibCoreStream.cpp b/Tests/LibCore/TestLibCoreStream.cpp index 0a81955fa7..3ee97091a1 100644 --- a/Tests/LibCore/TestLibCoreStream.cpp +++ b/Tests/LibCore/TestLibCoreStream.cpp @@ -422,7 +422,7 @@ TEST_CASE(buffered_long_file_read) { auto maybe_file = Core::File::open("/usr/Tests/LibCore/long_lines.txt"sv, Core::File::OpenMode::Read); EXPECT(!maybe_file.is_error()); - auto maybe_buffered_file = Core::BufferedFile::create(maybe_file.release_value()); + auto maybe_buffered_file = Core::InputBufferedFile::create(maybe_file.release_value()); EXPECT(!maybe_buffered_file.is_error()); auto file = maybe_buffered_file.release_value(); @@ -444,7 +444,7 @@ TEST_CASE(buffered_small_file_read) { auto maybe_file = Core::File::open("/usr/Tests/LibCore/small.txt"sv, Core::File::OpenMode::Read); EXPECT(!maybe_file.is_error()); - auto maybe_buffered_file = Core::BufferedFile::create(maybe_file.release_value()); + auto maybe_buffered_file = Core::InputBufferedFile::create(maybe_file.release_value()); EXPECT(!maybe_buffered_file.is_error()); auto file = maybe_buffered_file.release_value(); @@ -472,7 +472,7 @@ TEST_CASE(buffered_file_tell_and_seek) { // We choose a buffer size of 12 bytes to cover half of the input file. auto file = Core::File::open("/usr/Tests/LibCore/small.txt"sv, Core::File::OpenMode::Read).release_value(); - auto buffered_file = Core::BufferedFile::create(move(file), 12).release_value(); + auto buffered_file = Core::InputBufferedFile::create(move(file), 12).release_value(); // Initial state. { @@ -562,7 +562,7 @@ TEST_CASE(buffered_file_without_newlines) EXPECT(!file_wo_newlines->write_until_depleted(new_newlines_message.bytes()).is_error()); file_wo_newlines->close(); - auto ro_file = Core::BufferedFile::create(Core::File::open(filename, Core::File::OpenMode::Read).release_value(), new_newlines_message.length() + 1).release_value(); + auto ro_file = Core::InputBufferedFile::create(Core::File::open(filename, Core::File::OpenMode::Read).release_value(), new_newlines_message.length() + 1).release_value(); auto maybe_can_read_line = ro_file->can_read_line(); EXPECT(!maybe_can_read_line.is_error()); |