Add initial containerd *Client

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
Michael Crosby
2017-05-23 15:50:06 -07:00
parent 17033dcaf2
commit d0e5732f0b
10 changed files with 482 additions and 0 deletions

18
client_test.go Normal file
View File

@@ -0,0 +1,18 @@
package containerd
import "testing"
const defaultAddress = "/run/containerd/containerd.sock"
func TestNewClient(t *testing.T) {
client, err := New(defaultAddress)
if err != nil {
t.Fatal(err)
}
if client == nil {
t.Fatal("New() returned nil client")
}
if err := client.Close(); err != nil {
t.Errorf("client closed returned errror %v", err)
}
}