@@ -104,14 +104,14 @@ def wallet_file(name):
104
104
# w8 - to verify existing wallet file is loaded correctly. Not tested for SQLite wallets as this is a deprecated BDB behavior.
105
105
# '' - to verify default wallet file is created correctly
106
106
to_create = ['w1' , 'w2' , 'w3' , 'w' , 'sub/w5' , 'w7_symlink' ]
107
- in_wallet_dir = to_create . copy () # Wallets in the wallet dir
108
- in_wallet_dir .append ('w7' ) # w7 is not loaded or created, but will be listed by listwalletdir because w7_symlink
109
- to_create .append (os .path .join (self .options .tmpdir , 'extern/w6' )) # External, not in the wallet dir, so we need to avoid adding it to in_wallet_dir
107
+ in_wallet_dir = [ w . replace ( '/' , os . path . sep ) for w in to_create ] # Wallets in the wallet dir
108
+ in_wallet_dir .append ('w7' ) # w7 is not loaded or created, but will be listed by listwalletdir because w7_symlink
109
+ to_create .append (os .path .join (self .options .tmpdir , 'extern/w6' )) # External, not in the wallet dir, so we need to avoid adding it to in_wallet_dir
110
110
to_load = [self .default_wallet_name ]
111
111
if not self .options .descriptors :
112
112
to_load .append ('w8' )
113
- wallet_names = to_create + to_load # Wallet names loaded in the wallet
114
- in_wallet_dir += to_load # The loaded wallets are also in the wallet dir
113
+ wallet_names = to_create + to_load # Wallet names loaded in the wallet
114
+ in_wallet_dir += to_load # The loaded wallets are also in the wallet dir
115
115
self .start_node (0 )
116
116
for wallet_name in to_create :
117
117
self .nodes [0 ].createwallet (wallet_name )
@@ -298,7 +298,6 @@ def wallet_file(name):
298
298
# Fail to load if one wallet is a copy of another, test this twice to make sure that we don't re-introduce #14304
299
299
assert_raises_rpc_error (- 4 , "BerkeleyDatabase: Can't open database w8_copy (duplicates fileid" , self .nodes [0 ].loadwallet , 'w8_copy' )
300
300
301
-
302
301
# Fail to load if wallet file is a symlink
303
302
assert_raises_rpc_error (- 4 , "Wallet file verification failed. Invalid -wallet path 'w8_symlink'" , self .nodes [0 ].loadwallet , 'w8_symlink' )
304
303
@@ -397,5 +396,6 @@ def wallet_file(name):
397
396
self .nodes [0 ].unloadwallet (wallet )
398
397
self .nodes [1 ].loadwallet (wallet )
399
398
399
+
400
400
if __name__ == '__main__' :
401
401
MultiWalletTest ().main ()
0 commit comments