9#include <boost/test/unit_test.hpp>
19 std::string
u8_str =
"fs_tests_₿_🏃";
20 std::u8string
str8{
u8"fs_tests_₿_🏃"};
49 fs::path
tmpfolder = m_args.GetDataDirBase();
54 std::ofstream file{
tmpfile1.std_path()};
58 std::ifstream file{
tmpfile2.std_path()};
64 std::ifstream file{
tmpfile1.std_path(), std::ios_base::in | std::ios_base::ate};
70 std::ofstream file{
tmpfile2.std_path(), std::ios_base::out | std::ios_base::app};
74 std::ifstream file{
tmpfile1.std_path()};
80 std::ofstream file{
tmpfile2.std_path(), std::ios_base::out | std::ios_base::trunc};
84 std::ifstream file{
tmpfile1.std_path()};
110 const fs::path
tmpfolder{m_args.GetDataDirBase()};
119 std::ofstream file{
path1.std_path()};
124 std::ofstream file{
path2.std_path()};
134 std::ifstream file{
path2.std_path()};
BOOST_FIXTURE_TEST_SUITE(cuckoocache_tests, BasicTestingSetup)
Test Suite for CuckooCache.
BOOST_AUTO_TEST_SUITE_END()
static path u8path(std::string_view utf8_str)
static bool exists(const path &p)
static std::string PathToString(const path &path)
Convert path object to a byte string.
static path PathFromString(const std::string &string)
Convert byte string to path object.
bool RenameOver(fs::path src, fs::path dest)
Rename src to dest.
BOOST_AUTO_TEST_CASE(fsbridge_pathtostring)
fs::path AbsPathJoin(const fs::path &base, const fs::path &path)
Helper function for joining two paths.
#define BOOST_CHECK_EQUAL(v1, v2)
#define BOOST_CHECK(expr)
constexpr auto Ticks(Dur2 d)
Helper to count the seconds of a duration/time_point.