mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-11-10 22:27:22 +01:00
lntest+itest: finalize moving miner methods
This commit is contained in:
@@ -950,7 +950,7 @@ func testZeroConfReorg(ht *lntest.HarnessTest) {
|
||||
// exists in the graph.
|
||||
//
|
||||
// First, we'll setup a new miner that we can use to cause a reorg.
|
||||
tempMiner := ht.Miner.SpawnTempMiner()
|
||||
tempMiner := ht.SpawnTempMiner()
|
||||
|
||||
// We now cause a fork, by letting our original miner mine 1 block and
|
||||
// our new miner will mine 2. We also expect the funding transition to
|
||||
@@ -959,7 +959,7 @@ func testZeroConfReorg(ht *lntest.HarnessTest) {
|
||||
tempMiner.MineEmptyBlocks(2)
|
||||
|
||||
// Ensure the temp miner is one block ahead.
|
||||
ht.Miner.AssertMinerBlockHeightDelta(tempMiner, 1)
|
||||
ht.AssertMinerBlockHeightDelta(tempMiner, 1)
|
||||
|
||||
// Wait for Carol to sync to the original miner's chain.
|
||||
_, minerHeight := ht.GetBestBlock()
|
||||
@@ -972,14 +972,14 @@ func testZeroConfReorg(ht *lntest.HarnessTest) {
|
||||
|
||||
// Connecting to the temporary miner should cause the original miner to
|
||||
// reorg to the longer chain.
|
||||
ht.Miner.ConnectMiner(tempMiner)
|
||||
ht.ConnectToMiner(tempMiner)
|
||||
|
||||
// They should now be on the same chain.
|
||||
ht.Miner.AssertMinerBlockHeightDelta(tempMiner, 0)
|
||||
ht.AssertMinerBlockHeightDelta(tempMiner, 0)
|
||||
|
||||
// Now we disconnect the two miners and reconnect our original chain
|
||||
// backend.
|
||||
ht.Miner.DisconnectMiner(tempMiner)
|
||||
ht.DisconnectFromMiner(tempMiner)
|
||||
|
||||
ht.ConnectMiner()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user