lntest: specify lnd binary

Integration tests in external projects might not have the same folder
structure as lnd does. Therefore we want to allow the path to the
lnd itest binary to be configurable.
This commit is contained in:
Oliver Gugger committed 2020-01-03 09:17:23 +01:00
1 parent b762d441cf
commit ce711a1de7
3 files changed
+17 -7

No files matched your search

+2 -2
View File
@@ -369,11 +369,11 @@ func (hn *HarnessNode) InvoiceMacPath() string {
//
// This may not clean up properly if an error is returned, so the caller should
// call shutdown() regardless of the return value.
func (hn *HarnessNode) start(lndError chan<- error) error {
func (hn *HarnessNode) start(lndBinary string, lndError chan<- error) error {
hn.quit = make(chan struct{})
args := hn.Cfg.genArgs()
hn.cmd = exec.Command("../../lnd-itest", args...)
hn.cmd = exec.Command(lndBinary, args...)
// Redirect stderr output to buffer
var errb bytes.Buffer