mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 06:28:31 +01:00
scripted-diff: Modify unit tests to use the ArgsManager in the BasicTestingSetup class instead of implicitly relying on gArgs.
-BEGIN VERIFY SCRIPT- git ls-files src/test/dbwrapper_tests.cpp src/test/denialofservice_tests.cpp src/test/flatfile_tests.cpp src/test/fs_tests.cpp src/test/settings_tests.cpp src/test/util_tests.cpp | xargs sed -i 's/GetDataDir()/m_args.GetDataDirPath()/g'; -END VERIFY SCRIPT-
This commit is contained in:
@@ -14,7 +14,7 @@ BOOST_FIXTURE_TEST_SUITE(flatfile_tests, BasicTestingSetup)
|
||||
|
||||
BOOST_AUTO_TEST_CASE(flatfile_filename)
|
||||
{
|
||||
const auto data_dir = GetDataDir();
|
||||
const auto data_dir = m_args.GetDataDirPath();
|
||||
|
||||
FlatFilePos pos(456, 789);
|
||||
|
||||
@@ -27,7 +27,7 @@ BOOST_AUTO_TEST_CASE(flatfile_filename)
|
||||
|
||||
BOOST_AUTO_TEST_CASE(flatfile_open)
|
||||
{
|
||||
const auto data_dir = GetDataDir();
|
||||
const auto data_dir = m_args.GetDataDirPath();
|
||||
FlatFileSeq seq(data_dir, "a", 16 * 1024);
|
||||
|
||||
std::string line1("A purely peer-to-peer version of electronic cash would allow online "
|
||||
@@ -88,7 +88,7 @@ BOOST_AUTO_TEST_CASE(flatfile_open)
|
||||
|
||||
BOOST_AUTO_TEST_CASE(flatfile_allocate)
|
||||
{
|
||||
const auto data_dir = GetDataDir();
|
||||
const auto data_dir = m_args.GetDataDirPath();
|
||||
FlatFileSeq seq(data_dir, "a", 100);
|
||||
|
||||
bool out_of_space;
|
||||
@@ -108,7 +108,7 @@ BOOST_AUTO_TEST_CASE(flatfile_allocate)
|
||||
|
||||
BOOST_AUTO_TEST_CASE(flatfile_flush)
|
||||
{
|
||||
const auto data_dir = GetDataDir();
|
||||
const auto data_dir = m_args.GetDataDirPath();
|
||||
FlatFileSeq seq(data_dir, "a", 100);
|
||||
|
||||
bool out_of_space;
|
||||
|
||||
Reference in New Issue
Block a user