mirror of
https://github.com/hashicorp/vault.git
synced 2026-05-28 04:10:44 -04:00
Populate config error in three node test function
This commit is contained in:
parent
93c5d288d2
commit
8171eedc25
2 changed files with 5 additions and 2 deletions
|
|
@ -116,12 +116,12 @@ func DefaultConfig() *Config {
|
|||
}
|
||||
if err := http2.ConfigureTransport(transport); err != nil {
|
||||
config.Error = err
|
||||
return nil
|
||||
return config
|
||||
}
|
||||
|
||||
if err := config.ReadEnvironment(); err != nil {
|
||||
config.Error = err
|
||||
return nil
|
||||
return config
|
||||
}
|
||||
|
||||
// Ensure redirects are not automatically followed
|
||||
|
|
|
|||
|
|
@ -1275,6 +1275,9 @@ func NewTestCluster(t testing.T, base *CoreConfig, opts *TestClusterOptions) *Te
|
|||
},
|
||||
}
|
||||
config := api.DefaultConfig()
|
||||
if config.Error != nil {
|
||||
t.Fatal(config.Error)
|
||||
}
|
||||
config.Address = fmt.Sprintf("https://127.0.0.1:%d", port)
|
||||
config.HttpClient = client
|
||||
apiClient, err := api.NewClient(config)
|
||||
|
|
|
|||
Loading…
Reference in a new issue