Fix remaining failing tests

This commit is contained in:
Kovid Goyal
2023-02-25 10:27:01 +05:30
parent dc938cf3dd
commit 5cc3d3cbfe
8 changed files with 33 additions and 22 deletions

View File

@@ -50,10 +50,13 @@ func basic_connection_data(overrides ...string) *connection_data {
script_type: "sh", request_id: "123-123", remote_args: []string{},
username: "testuser", hostname_for_match: "host.test",
}
opts, err := load_config(ans.hostname_for_match, ans.username, overrides, "")
opts, bad_lines, err := load_config(ans.hostname_for_match, ans.username, overrides, "")
if err != nil {
panic(err)
}
if len(bad_lines) != 0 {
panic(fmt.Sprintf("Bad config lines: %s with error: %s", bad_lines[0].Line, bad_lines[0].Err))
}
ans.host_opts = opts
return ans
}