diff --git a/cmd/mesh-controller/terminal_settings_test.go b/cmd/mesh-controller/terminal_settings_test.go index 3c8c4d8d..3962862a 100644 --- a/cmd/mesh-controller/terminal_settings_test.go +++ b/cmd/mesh-controller/terminal_settings_test.go @@ -9,6 +9,8 @@ import ( "testing" "git.novox.be/novox/mesh-sdk/go/catalogue" + + "github.com/novox/mesh-controller/internal/broker" ) // Where root creates and owns a module's directories, and which of the machine's paths reach its container, @@ -39,8 +41,10 @@ func atTheTerminal(t *testing.T, argv ...string) error { func runLine(t *testing.T, argv []string) error { t.Helper() - before := os.Args - defer func() { os.Args = before }() + before, named := os.Args, broker.ConnectionName + // run names every connection this process dials after the line's verb; a later test in this process would dial as + // that verb (issue 1945: a conditions test saw "mesh-controller verb settings"). + defer func() { os.Args, broker.ConnectionName = before, named }() os.Args = append([]string{"mesh-controller"}, argv...) return run() }