1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00
moby--moby/engine/helpers_test.go

25 lines
394 B
Go
Raw Normal View History

2013-10-23 04:35:26 -04:00
package engine
import (
"github.com/dotcloud/docker/utils"
2013-11-07 15:19:24 -05:00
"testing"
2013-10-23 04:35:26 -04:00
)
var globalTestID string
func newTestEngine(t *testing.T) *Engine {
tmp, err := utils.TestDirectory("")
2013-10-23 04:35:26 -04:00
if err != nil {
t.Fatal(err)
}
eng, err := New(tmp)
2013-10-23 04:35:26 -04:00
if err != nil {
t.Fatal(err)
}
return eng
}
func mkJob(t *testing.T, name string, args ...string) *Job {
return newTestEngine(t).Job(name, args...)
2013-10-23 04:35:26 -04:00
}