Fix tests

This commit is contained in:
Brian Kassouf 2017-04-21 09:10:26 -07:00
parent 798fc922d1
commit 30b06b593c
3 changed files with 1 additions and 6 deletions

View File

@ -23,6 +23,7 @@ type MySQL struct {
credsutil.CredentialsProducer credsutil.CredentialsProducer
} }
// New implements builtinplugins.BuiltinFactory
func New() (interface{}, error) { func New() (interface{}, error) {
connProducer := &connutil.SQLConnectionProducer{} connProducer := &connutil.SQLConnectionProducer{}
connProducer.Type = mySQLTypeName connProducer.Type = mySQLTypeName

View File

@ -1122,8 +1122,6 @@ func TestSystemBackend_PluginCatalog_CRUD(t *testing.T) {
t.Fatalf("error: %v", err) t.Fatalf("error: %v", err)
} }
c.pluginCatalog.directory = sym c.pluginCatalog.directory = sym
c.pluginCatalog.vaultCommand = "vault"
c.pluginCatalog.vaultSHA256 = []byte{'1'}
req := logical.TestRequest(t, logical.ListOperation, "plugin-catalog/") req := logical.TestRequest(t, logical.ListOperation, "plugin-catalog/")
resp, err := b.HandleRequest(req) resp, err := b.HandleRequest(req)

View File

@ -21,8 +21,6 @@ func TestPluginCatalog_CRUD(t *testing.T) {
t.Fatalf("error: %v", err) t.Fatalf("error: %v", err)
} }
core.pluginCatalog.directory = sym core.pluginCatalog.directory = sym
core.pluginCatalog.vaultCommand = "vault"
core.pluginCatalog.vaultSHA256 = []byte{'1'}
// Get builtin plugin // Get builtin plugin
p, err := core.pluginCatalog.Get("mysql-database-plugin") p, err := core.pluginCatalog.Get("mysql-database-plugin")
@ -99,8 +97,6 @@ func TestPluginCatalog_List(t *testing.T) {
t.Fatalf("error: %v", err) t.Fatalf("error: %v", err)
} }
core.pluginCatalog.directory = sym core.pluginCatalog.directory = sym
core.pluginCatalog.vaultCommand = "vault"
core.pluginCatalog.vaultSHA256 = []byte{'1'}
// Get builtin plugins and sort them // Get builtin plugins and sort them
builtinKeys := builtinplugins.BuiltinPlugins.Keys() builtinKeys := builtinplugins.BuiltinPlugins.Keys()