mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-11-01 19:17:58 +00:00
Fix failing TestHCPLinkConnected Test (#19474)
* replace use of os.Unsetenv in test with t.Setenv and remove t.Parallel from test that rely on env being modified. * experiment with using fromJSON function * revert previous experiment * including double quotes in the output value for the string ubuntu-latest * use go run to launch gofumpt
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package server
|
||||
|
||||
import (
|
||||
"os"
|
||||
"testing"
|
||||
|
||||
"github.com/go-test/deep"
|
||||
@@ -10,9 +9,9 @@ import (
|
||||
)
|
||||
|
||||
func TestHCPLinkConfig(t *testing.T) {
|
||||
os.Unsetenv("HCP_CLIENT_ID")
|
||||
os.Unsetenv("HCP_CLIENT_SECRET")
|
||||
os.Unsetenv("HCP_RESOURCE_ID")
|
||||
t.Setenv("HCP_CLIENT_ID", "")
|
||||
t.Setenv("HCP_CLIENT_SECRET", "")
|
||||
t.Setenv("HCP_RESOURCE_ID", "")
|
||||
|
||||
config, err := LoadConfigFile("./test-fixtures/hcp_link_config.hcl")
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user