cleanup metrics_du_test in /tmp

Signed-off-by: Jess Frazelle <acidburn@google.com>
This commit is contained in:
Jess Frazelle 2016-12-14 14:58:25 -08:00
parent a2dbd456a7
commit ba617fdd1b
No known key found for this signature in database
GPG Key ID: 18F3685C0022BFF3

View File

@ -507,6 +507,7 @@ func FindEmptyDirectoryUsageOnTmpfs() (*resource.Quantity, error) {
if err != nil {
return nil, err
}
defer os.RemoveAll(tmpDir)
out, err := exec.Command("nice", "-n", "19", "du", "-s", "-B", "1", tmpDir).CombinedOutput()
if err != nil {
return nil, fmt.Errorf("failed command 'du' on %s with error %v", tmpDir, err)