Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/llfio.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNiall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com>2018-08-24 11:59:28 +0300
committerNiall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com>2018-08-24 11:59:28 +0300
commit5f82c897584065164c593ea0ca3a602ac651198c (patch)
tree4e1a880af2902e11561aa4608af1d1d1c77f35d6 /test/tests/directory_handle_enumerate
parent0b0eae81e199476a1f5246c68011bd00d8653363 (diff)
Reworked directory_handle to use same io_request and read() pattern as all the other handles.
Diffstat (limited to 'test/tests/directory_handle_enumerate')
-rw-r--r--test/tests/directory_handle_enumerate/kernel_directory_handle_enumerate.cpp.hpp4
-rw-r--r--test/tests/directory_handle_enumerate/runner.cpp12
2 files changed, 8 insertions, 8 deletions
diff --git a/test/tests/directory_handle_enumerate/kernel_directory_handle_enumerate.cpp.hpp b/test/tests/directory_handle_enumerate/kernel_directory_handle_enumerate.cpp.hpp
index b4500928..d871cad7 100644
--- a/test/tests/directory_handle_enumerate/kernel_directory_handle_enumerate.cpp.hpp
+++ b/test/tests/directory_handle_enumerate/kernel_directory_handle_enumerate.cpp.hpp
@@ -26,10 +26,10 @@ Distributed under the Boost Software License, Version 1.0.
namespace directory_handle_enumerate
{
- LLFIO_TEST_KERNEL_DECL LLFIO_V2_NAMESPACE::result<LLFIO_V2_NAMESPACE::directory_handle::enumerate_info> test_kernel_directory_handle_enumerate(LLFIO_V2_NAMESPACE::span<LLFIO_V2_NAMESPACE::directory_entry> *buffers, LLFIO_V2_NAMESPACE::path_view glob, LLFIO_V2_NAMESPACE::directory_handle::filter filtering)
+ LLFIO_TEST_KERNEL_DECL LLFIO_V2_NAMESPACE::result<LLFIO_V2_NAMESPACE::directory_handle::buffers_type> test_kernel_directory_handle_enumerate(LLFIO_V2_NAMESPACE::span<LLFIO_V2_NAMESPACE::directory_entry> *buffers, LLFIO_V2_NAMESPACE::path_view glob, LLFIO_V2_NAMESPACE::directory_handle::filter filtering)
{
OUTCOME_TRY(h, LLFIO_V2_NAMESPACE::directory_handle::directory({}, "."));
- auto ret = h.enumerate(*buffers, glob, filtering);
+ auto ret = h.read({*buffers, glob, filtering});
h.close().value();
return ret;
}
diff --git a/test/tests/directory_handle_enumerate/runner.cpp b/test/tests/directory_handle_enumerate/runner.cpp
index 99bc10b7..4ab1d872 100644
--- a/test/tests/directory_handle_enumerate/runner.cpp
+++ b/test/tests/directory_handle_enumerate/runner.cpp
@@ -73,25 +73,25 @@ template <class U> inline void directory_handle_enumerate_(U &&f)
{
path_view glob = std::get<1>(std::get<1>(permuter[idx]));
filter filtered = std::get<2>(std::get<1>(permuter[idx]));
- directory_handle::enumerate_info info(std::move(testreturn.value()));
- KERNELTEST_CHECK(testreturn, info.done == true);
+ directory_handle::buffers_type info(std::move(testreturn.value()));
+ KERNELTEST_CHECK(testreturn, info.done() == true);
if (!glob.empty())
{
- KERNELTEST_CHECK(testreturn, info.filled.size() == 1);
+ KERNELTEST_CHECK(testreturn, info.size() == 1);
}
else if (filtered == filter::fastdeleted)
{
- KERNELTEST_CHECK(testreturn, info.filled.size() == 3);
+ KERNELTEST_CHECK(testreturn, info.size() == 3);
}
else
{
- KERNELTEST_CHECK(testreturn, info.filled.size() == 4);
+ KERNELTEST_CHECK(testreturn, info.size() == 4);
}
bool havedeleted1 = !glob.empty();
bool havedeleted2 = (filtered == filter::fastdeleted);
bool havefoo = false;
bool havedir = !glob.empty();
- for (directory_entry &i : info.filled)
+ for (directory_entry &i : info)
{
if (i.leafname == "012345678901234567890123456789012345678901234567890123456789012z.deleted")
{