summaryrefslogtreecommitdiff
path: root/test/e2e/libpod_suite_test.go
diff options
context:
space:
mode:
authorbaude <bbaude@redhat.com>2018-10-10 12:22:35 -0500
committerbaude <bbaude@redhat.com>2018-10-23 08:26:21 -0500
commitee8f19e7be8626b17498a3c5602a7390a4d671e3 (patch)
treed9846560bf0723305600e9cf43749536c9befd14 /test/e2e/libpod_suite_test.go
parent5b2478ed87eedd8178c1672a786f95a6716a8edb (diff)
downloadpodman-ee8f19e7be8626b17498a3c5602a7390a4d671e3.tar.gz
podman-ee8f19e7be8626b17498a3c5602a7390a4d671e3.tar.bz2
podman-ee8f19e7be8626b17498a3c5602a7390a4d671e3.zip
Make podman ps fast
Like Ricky Bobby, we want to go fast. Signed-off-by: baude <bbaude@redhat.com>
Diffstat (limited to 'test/e2e/libpod_suite_test.go')
-rw-r--r--test/e2e/libpod_suite_test.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/e2e/libpod_suite_test.go b/test/e2e/libpod_suite_test.go
index a032b0e88..f34e9c5e7 100644
--- a/test/e2e/libpod_suite_test.go
+++ b/test/e2e/libpod_suite_test.go
@@ -315,8 +315,14 @@ func (s *PodmanSession) OutputToString() string {
// OutputToStringArray returns the output as a []string
// where each array item is a line split by newline
func (s *PodmanSession) OutputToStringArray() []string {
+ var results []string
output := fmt.Sprintf("%s", s.Out.Contents())
- return strings.Split(output, "\n")
+ for _, line := range strings.Split(output, "\n") {
+ if line != "" {
+ results = append(results, line)
+ }
+ }
+ return results
}
// ErrorGrepString takes session stderr output and behaves like grep. it returns a bool