Skip to content

Commit 9d26b69

Browse files
committed
Merge #13687: travis: Check that ~/.bitcoin is never created
fabe28a qa: Temporarily disable test that reads the default datadir location (MarcoFalke) 41a8c8d travis: Check that ~/.bitcoin is never created (MarcoFalke) Pull request description: Tree-SHA512: d114db29a18f684d207caa0d7c947b13c945e2dd8b6d7fdeacdf7aa194f8123579d1139331b9d308df69a1132796e805a9ab63580aebde9b719860c0ff4b5652
2 parents 0d8d6be + fabe28a commit 9d26b69

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ install:
5353
- travis_retry DOCKER_EXEC apt-get update
5454
- travis_retry DOCKER_EXEC apt-get install --no-install-recommends --no-upgrade -qq $PACKAGES $DOCKER_PACKAGES
5555
before_script:
56+
- DOCKER_EXEC echo \> \$HOME/.bitcoin # Make sure default datadir does not exist and is never read by creating a dummy file
5657
- mkdir -p depends/SDKs depends/sdk-sources
5758
- if [ -n "$OSX_SDK" -a ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
5859
- if [ -n "$OSX_SDK" -a -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi

test/functional/feature_config_args.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,15 @@ def run_test(self):
3636
f.write("datadir=" + new_data_dir + "\n")
3737
f.write(conf_file_contents)
3838

39-
self.nodes[0].assert_start_raises_init_error(['-conf=' + conf_file], 'Error reading configuration file: specified data directory "' + new_data_dir + '" does not exist.')
39+
# Temporarily disabled, because this test would access the user's home dir (~/.bitcoin)
40+
#self.nodes[0].assert_start_raises_init_error(['-conf=' + conf_file], 'Error reading configuration file: specified data directory "' + new_data_dir + '" does not exist.')
4041

4142
# Create the directory and ensure the config file now works
4243
os.mkdir(new_data_dir)
43-
self.start_node(0, ['-conf='+conf_file, '-wallet=w1'])
44-
self.stop_node(0)
45-
assert os.path.exists(os.path.join(new_data_dir, 'regtest', 'wallets', 'w1'))
44+
# Temporarily disabled, because this test would access the user's home dir (~/.bitcoin)
45+
#self.start_node(0, ['-conf='+conf_file, '-wallet=w1'])
46+
#self.stop_node(0)
47+
#assert os.path.exists(os.path.join(new_data_dir, 'regtest', 'wallets', 'w1'))
4648

4749
# Ensure command line argument overrides datadir in conf
4850
os.mkdir(new_data_dir_2)

0 commit comments

Comments
 (0)