doc: test: update/fix TestShell example instructions

Tackles two issues in the TestShell documentation:
- add missing instruction for creating a wallet prior to the
  `getnewaddress` call (needed as there is no default wallet created
  anymore since v0.21)
- fix `generatetoaddress` call syntax (the scripted-diff in commit
  fa0b916971 only worked for tests using
  `BitcoinTestFramework`)
pull/26520/head
Sebastian Falbesoner 2 years ago
parent 82fe672ea0
commit 31d0067f8b

@ -93,8 +93,10 @@ We now let the first node generate 101 regtest blocks, and direct the coinbase
rewards to a wallet address owned by the mining node.
```
>>> test.nodes[0].createwallet('default')
{'name': 'default', 'warning': 'Empty string given as passphrase, wallet will not be encrypted.'}
>>> address = test.nodes[0].getnewaddress()
>>> test.self.generatetoaddress(nodes[0], 101, address)
>>> test.generatetoaddress(test.nodes[0], 101, address)
['2b98dd0044aae6f1cca7f88a0acf366a4bfe053c7f7b00da3c0d115f03d67efb', ...
```
Since the two nodes are both initialized by default to establish an outbound

Loading…
Cancel
Save