mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-19 13:27:35 +02:00
Introduce GetUniquePath(base) helper method to replace boost::filesystem::unique_path() which is not available in std::filesystem.
This commit is contained in:
parent
ea5a50f92a
commit
1bca2aa694
6 changed files with 52 additions and 3 deletions
|
|
@ -13,6 +13,7 @@
|
|||
#include <test/util/setup_common.h>
|
||||
#include <test/util/str.h>
|
||||
#include <uint256.h>
|
||||
#include <util/getuniquepath.h>
|
||||
#include <util/message.h> // For MessageSign(), MessageVerify(), MESSAGE_MAGIC
|
||||
#include <util/moneystr.h>
|
||||
#include <util/spanparsing.h>
|
||||
|
|
@ -1816,7 +1817,7 @@ BOOST_AUTO_TEST_CASE(test_DirIsWritable)
|
|||
BOOST_CHECK_EQUAL(DirIsWritable(tmpdirname), true);
|
||||
|
||||
// Should not be able to write to a non-existent dir.
|
||||
tmpdirname = tmpdirname / fs::unique_path();
|
||||
tmpdirname = GetUniquePath(tmpdirname);
|
||||
BOOST_CHECK_EQUAL(DirIsWritable(tmpdirname), false);
|
||||
|
||||
fs::create_directory(tmpdirname);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue