add test
This commit is contained in:
parent
e6670fc4a0
commit
de12432e6b
|
@ -594,10 +594,11 @@ func TestCreateCmdArgs(t *testing.T) {
|
|||
p.config.AnsibleEnvVars = tc.AnsibleEnvVars
|
||||
|
||||
args, envVars := p.createCmdArgs(tc.callArgs[0], tc.callArgs[1], tc.callArgs[2], tc.callArgs[3])
|
||||
|
||||
assert.ElementsMatch(t, args, tc.ExpectedArgs,
|
||||
"Args didn't match expected:\n\n expected: \n%s\n; recieved: \n%s\n", tc.ExpectedArgs, args)
|
||||
assert.ElementsMatch(t, envVars, tc.ExpectedEnvVars, "EnvVars didn't match expected:\n\n expected: \n%s\n; recieved: \n%s\n", tc.ExpectedEnvVars, envVars)
|
||||
assert.ElementsMatch(t, args[len(args)-1], p.config.PlaybookFile,
|
||||
"PlayBook File Not Returned as last element: expected \n%s\n; recieved: \n%s\n", args[len(args)-1], p.config.PlaybookFile)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue