@ -71,7 +71,7 @@ class MultiWalletTest(BitcoinTestFramework):
wallet_names = [ ' w1 ' , ' w2 ' , ' w3 ' , ' w ' , ' sub/w5 ' , os . path . join ( self . options . tmpdir , ' extern/w6 ' ) , ' w7_symlink ' , ' w8 ' , ' ' ]
wallet_names = [ ' w1 ' , ' w2 ' , ' w3 ' , ' w ' , ' sub/w5 ' , os . path . join ( self . options . tmpdir , ' extern/w6 ' ) , ' w7_symlink ' , ' w8 ' , ' ' ]
extra_args = [ ' -wallet= {} ' . format ( n ) for n in wallet_names ]
extra_args = [ ' -wallet= {} ' . format ( n ) for n in wallet_names ]
self . start_node ( 0 , extra_args )
self . start_node ( 0 , extra_args )
assert_equal ( s et ( map ( lambda w : w [ ' name ' ] , self . nodes [ 0 ] . listwalletdir ( ) [ ' wallets ' ] ) ) , set ( [ ' ' , ' w3 ' , ' w2 ' , os . path . join ( ' sub ' , ' w5 ' ) , ' w 7 ' , ' w 7' , ' w1 ' , ' w8 ' , ' w ' ] ) )
assert_equal ( s orted ( map ( lambda w : w [ ' name ' ] , self . nodes [ 0 ] . listwalletdir ( ) [ ' wallets ' ] ) ) , [ ' ' , os . path . join ( ' sub ' , ' w5 ' ) , ' w ' , ' w 1' , ' w2 ' , ' w3 ' , ' w7 ' , ' w7_symlink ' , ' w8 ' ] )
assert_equal ( set ( node . listwallets ( ) ) , set ( wallet_names ) )
assert_equal ( set ( node . listwallets ( ) ) , set ( wallet_names ) )
@ -144,7 +144,7 @@ class MultiWalletTest(BitcoinTestFramework):
self . restart_node ( 0 , extra_args )
self . restart_node ( 0 , extra_args )
assert_equal ( s et ( map ( lambda w : w [ ' name ' ] , self . nodes [ 0 ] . listwalletdir ( ) [ ' wallets ' ] ) ) , set ( [ ' ' , ' w3 ' , ' w2 ' , os . path . join ( ' sub ' , ' w5 ' ) , ' w 7 ' , ' w 7' , ' w8_copy ' , ' w1 ' , ' w8 ' , ' w ' ] ) )
assert_equal ( s orted ( map ( lambda w : w [ ' name ' ] , self . nodes [ 0 ] . listwalletdir ( ) [ ' wallets ' ] ) ) , [ ' ' , os . path . join ( ' sub ' , ' w5 ' ) , ' w ' , ' w 1' , ' w2 ' , ' w3 ' , ' w7 ' , ' w7_symlink ' , ' w8 ' , ' w 8_copy ' ] )
wallets = [ wallet ( w ) for w in wallet_names ]
wallets = [ wallet ( w ) for w in wallet_names ]
wallet_bad = wallet ( " bad " )
wallet_bad = wallet ( " bad " )
@ -291,7 +291,7 @@ class MultiWalletTest(BitcoinTestFramework):
assert_equal ( self . nodes [ 0 ] . listwallets ( ) , [ ' w1 ' ] )
assert_equal ( self . nodes [ 0 ] . listwallets ( ) , [ ' w1 ' ] )
assert_equal ( w1 . getwalletinfo ( ) [ ' walletname ' ] , ' w1 ' )
assert_equal ( w1 . getwalletinfo ( ) [ ' walletname ' ] , ' w1 ' )
assert_equal ( s et ( map ( lambda w : w [ ' name ' ] , self . nodes [ 0 ] . listwalletdir ( ) [ ' wallets ' ] ) ) , set ( [ ' ' , ' w3 ' , ' w2 ' , os . path . join ( ' sub ' , ' w5 ' ) , ' w 7 ' , ' w 9 ' , ' w7 ' , ' w 8_copy' , ' w1 ' , ' w8 ' , ' w ' ] ) )
assert_equal ( s orted ( map ( lambda w : w [ ' name ' ] , self . nodes [ 0 ] . listwalletdir ( ) [ ' wallets ' ] ) ) , [ ' ' , os . path . join ( ' sub ' , ' w5 ' ) , ' w ' , ' w 1' , ' w2 ' , ' w3 ' , ' w7 ' , ' w 7_symlink ' , ' w8 ' , ' w 8_copy' , ' w9 ' ] )
# Test backing up and restoring wallets
# Test backing up and restoring wallets
self . log . info ( " Test wallet backup " )
self . log . info ( " Test wallet backup " )