mirror of https://github.com/docker/docs.git
Use temp dir instead of default dir
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
This commit is contained in:
parent
80436e9b66
commit
63bdda0645
|
|
@ -1,6 +1,7 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"io/ioutil"
|
||||
"os/exec"
|
||||
"testing"
|
||||
|
||||
|
|
@ -65,7 +66,10 @@ func (d *FakeDriver) GetSSHCommand(args ...string) (*exec.Cmd, error) {
|
|||
}
|
||||
|
||||
func TestGetHostState(t *testing.T) {
|
||||
storePath := "~/.docker"
|
||||
storePath, err := ioutil.TempDir("", ".docker")
|
||||
if err != nil {
|
||||
t.Fatal("Error creating tmp dir:", err)
|
||||
}
|
||||
hostListItems := make(chan hostListItem)
|
||||
store := NewStore(storePath)
|
||||
hosts := []Host{
|
||||
|
|
|
|||
Loading…
Reference in New Issue