mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-17 23:19:26 +00:00
Remove dependency on test/integration from kubemark
This commit is contained in:
@@ -18,9 +18,7 @@ package integration
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"math/rand"
|
||||
"os"
|
||||
"testing"
|
||||
|
||||
etcd "github.com/coreos/etcd/client"
|
||||
@@ -67,20 +65,6 @@ func deleteAllEtcdKeys() {
|
||||
|
||||
}
|
||||
|
||||
func MakeTempDirOrDie(prefix string, baseDir string) string {
|
||||
if baseDir == "" {
|
||||
baseDir = "/tmp"
|
||||
}
|
||||
tempDir, err := ioutil.TempDir(baseDir, prefix)
|
||||
if err != nil {
|
||||
glog.Fatalf("Can't make a temp rootdir: %v", err)
|
||||
}
|
||||
if err = os.MkdirAll(tempDir, 0750); err != nil {
|
||||
glog.Fatalf("Can't mkdir(%q): %v", tempDir, err)
|
||||
}
|
||||
return tempDir
|
||||
}
|
||||
|
||||
func deletePodOrErrorf(t *testing.T, c *client.Client, ns, name string) {
|
||||
if err := c.Pods(ns).Delete(name, nil); err != nil {
|
||||
t.Errorf("unable to delete pod %v: %v", name, err)
|
||||
|
Reference in New Issue
Block a user