mirror of
https://github.com/minio/minio.git
synced 2026-11-18 14:59:20 +00:00
Switching execpipe output to io.Reader
This commit is contained in:
1 parent
d1fe8beff5
commit
14dec50fef
2 files changed
+11
-6
No files matched your search
@@ -3,9 +3,11 @@
|
||||
package utils
|
||||
|
||||
import (
|
||||
. "gopkg.in/check.v1"
|
||||
"io/ioutil"
|
||||
"os/exec"
|
||||
"testing"
|
||||
|
||||
. "gopkg.in/check.v1"
|
||||
)
|
||||
|
||||
type MySuite struct{}
|
||||
@@ -29,6 +31,8 @@ func (s *MySuite) TestPiping(c *C) {
|
||||
// Run
|
||||
output, err := ExecPipe(ls, sort)
|
||||
c.Assert(err, IsNil)
|
||||
c.Assert(len(output), Not(Equals), 0)
|
||||
outputBytes, err := ioutil.ReadAll(output)
|
||||
c.Assert(err, IsNil)
|
||||
c.Assert(len(outputBytes), Not(Equals), 0)
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user