lnwallet: integrate obfuscated state hints into funding workflow
This commit finalizes the implementation of #58 by integrating passing around the obfuscate state hints into the funding workflow of the wallet, and also the daemon’s funding manager. In order to amend the tests, the functions to set and receive the state hints are now publicly exported.
This commit is contained in:
6 files changed
+147
-34
No files matched your search
@@ -547,12 +547,12 @@ func TestCommitTxStateHint(t *testing.T) {
|
||||
for i := 0; i < 10000; i++ {
|
||||
stateNum := uint32(i)
|
||||
|
||||
err := setStateNumHint(commitTx, stateNum, obsfucator)
|
||||
err := SetStateNumHint(commitTx, stateNum, obsfucator)
|
||||
if err != nil {
|
||||
t.Fatalf("unable to set state num %v: %v", i, err)
|
||||
}
|
||||
|
||||
extractedStateNum := getStateNumHint(commitTx, obsfucator)
|
||||
extractedStateNum := GetStateNumHint(commitTx, obsfucator)
|
||||
if extractedStateNum != stateNum {
|
||||
t.Fatalf("state number mismatched, expected %v, got %v",
|
||||
stateNum, extractedStateNum)
|
||||
|
||||
Reference in new issue
Block a user