Plugins JSON spec.

Allow full configuration of external plugins via a JSON document.

Signed-off-by: David Calavera <david.calavera@gmail.com>
This commit is contained in:
David Calavera 2015-05-27 15:21:18 -07:00
parent b4f6e2c8b7
commit 7312c4b8bb
6 changed files with 145 additions and 43 deletions

View file

@ -7,6 +7,8 @@ import (
"reflect"
"testing"
"time"
"github.com/docker/docker/pkg/tlsconfig"
)
var (
@ -27,7 +29,7 @@ func teardownRemotePluginServer() {
}
func TestFailedConnection(t *testing.T) {
c := NewClient("tcp://127.0.0.1:1")
c, _ := NewClient("tcp://127.0.0.1:1", tlsconfig.Options{InsecureSkipVerify: true})
err := c.callWithRetry("Service.Method", nil, nil, false)
if err == nil {
t.Fatal("Unexpected successful connection")
@ -51,7 +53,7 @@ func TestEchoInputOutput(t *testing.T) {
io.Copy(w, r.Body)
})
c := NewClient(addr)
c, _ := NewClient(addr, tlsconfig.Options{InsecureSkipVerify: true})
var output Manifest
err := c.Call("Test.Echo", m, &output)
if err != nil {