From 26e1975edcfaed8807149280c45de38030e02529 Mon Sep 17 00:00:00 2001 From: "Scott E. Graves" Date: Thu, 24 Oct 2024 08:02:39 -0500 Subject: [PATCH] added winfsp test executable --- .../include/fixtures/winfsp_fixture.hpp | 4 ++-- repertory/repertory_test/src/winfsp_drive_test.cpp | 14 +++++++++++--- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/repertory/repertory_test/include/fixtures/winfsp_fixture.hpp b/repertory/repertory_test/include/fixtures/winfsp_fixture.hpp index a46c0ec3..7d7d8e6b 100644 --- a/repertory/repertory_test/include/fixtures/winfsp_fixture.hpp +++ b/repertory/repertory_test/include/fixtures/winfsp_fixture.hpp @@ -21,7 +21,7 @@ */ #ifndef REPERTORY_TEST_INCLUDE_FIXTURES_WINFSP_FIXTURE_HPP #define REPERTORY_TEST_INCLUDE_FIXTURES_WINFSP_FIXTURE_HPP -#if 0 +// #if 0 #if defined(_WIN32) #include "test_common.hpp" @@ -247,5 +247,5 @@ using winfsp_provider_types = ::testing::Types; } // namespace repertory #endif // defined(_WIN32) -#endif // 0 +// #endif // 0 #endif // REPERTORY_TEST_INCLUDE_FIXTURES_WINFSP_FIXTURE_HPP diff --git a/repertory/repertory_test/src/winfsp_drive_test.cpp b/repertory/repertory_test/src/winfsp_drive_test.cpp index 641537b9..07434e25 100644 --- a/repertory/repertory_test/src/winfsp_drive_test.cpp +++ b/repertory/repertory_test/src/winfsp_drive_test.cpp @@ -20,7 +20,7 @@ SOFTWARE. */ #if defined(_WIN32) -// #if 0 +#if 0 #include "fixtures/winfsp_fixture.hpp" @@ -224,12 +224,20 @@ TYPED_TEST(winfsp_test, run_winfsp_tests) { auto cur = std::filesystem::current_path(); std::filesystem::current_path(this->mount_location); - auto res = system("winfsp-tests-x64.exe --external --resilient"); + std::vector test_options{ + "--external", + "--resilient", + }; + + auto res = + system((utils::path::combine(cur.string(), {"winfsp-tests-x64.exe"}) + + ' ' + utils::string::join(test_options, ' ')) + .c_str()); EXPECT_EQ(0, res); std::filesystem::current_path(cur); } } // namespace repertory -// #endif // 0 +#endif // 0 #endif // defined(_WIN32)