From e6a5a56aa6b0ef25eb6ae47de6b5415f84259991 Mon Sep 17 00:00:00 2001 From: 5eraph <5eraph@protonmail.com> Date: Tue, 4 Aug 2020 15:18:02 +0200 Subject: changes to support outbound-addr Fixes #6064 Signed-off-by: Bohumil Cervenka <5eraph@protonmail.com> --- test/utils/utils.go | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'test/utils') diff --git a/test/utils/utils.go b/test/utils/utils.go index 2c454f532..8ee702423 100644 --- a/test/utils/utils.go +++ b/test/utils/utils.go @@ -341,6 +341,16 @@ func SystemExec(command string, args []string) *PodmanSession { return &PodmanSession{session} } +// StartSystemExec is used to start exec a system command +func StartSystemExec(command string, args []string) *PodmanSession { + c := exec.Command(command, args...) + session, err := gexec.Start(c, GinkgoWriter, GinkgoWriter) + if err != nil { + Fail(fmt.Sprintf("unable to run command: %s %s", command, strings.Join(args, " "))) + } + return &PodmanSession{session} +} + // StringInSlice determines if a string is in a string slice, returns bool func StringInSlice(s string, sl []string) bool { for _, i := range sl { -- cgit v1.2.3-54-g00ecf