Use a thread-safe MemoryDatabase
This commit is contained in:
@@ -12,13 +12,13 @@ class LibTest {
|
||||
val desc =
|
||||
"wpkh([c258d2e4/84h/1h/0h]tpubDDYkZojQFQjht8Tm4jsS3iuEmKjTiEGjG6KnuFNKKJb5A6ZUCUZKdvLdSDWofKi4ToRCwb9poe1XdqfUnP4jaJjCB2Zwv11ZLgSbnZSNecE/0/*)"
|
||||
|
||||
// @Test
|
||||
// fun walletNewAddress() {
|
||||
// val wallet = OfflineWallet(desc)
|
||||
// val address = wallet.getNewAddress()
|
||||
// assertNotNull(address)
|
||||
// assertEquals(address, "bcrt1qzg4mckdh50nwdm9hkzq06528rsu73hjxytqkxs")
|
||||
// }
|
||||
@Test
|
||||
fun walletNewAddress() {
|
||||
val wallet = OfflineWallet(desc)
|
||||
val address = wallet.getNewAddress()
|
||||
assertNotNull(address)
|
||||
assertEquals(address, "bcrt1qzg4mckdh50nwdm9hkzq06528rsu73hjxytqkxs")
|
||||
}
|
||||
|
||||
@Test(expected=BdkException.Descriptor::class)
|
||||
fun invalidDescriptorExceptionIsThrown() {
|
||||
|
||||
Reference in New Issue
Block a user