diff --git a/Jenkinsfile b/Jenkinsfile index 64f1f9c..51c90e3 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -30,7 +30,7 @@ pipeline { stages { stage('Test') { environment { - BYPASS_XOA_TOKEN = sh(script: "xo-cli --createToken $XOA_URL $XOA_USER $XOA_PASSWORD | tail -n1", returnStdout: true) + BYPASS_XOA_TOKEN = sh(script: "xo-cli --createToken $XOA_URL $XOA_USER $XOA_PASSWORD | tail -n1", returnStdout: true).trim() } steps { lock('xoa-test-runner') { diff --git a/Makefile b/Makefile index 80a93b9..1672de9 100644 --- a/Makefile +++ b/Makefile @@ -46,4 +46,4 @@ testacc: xoa/testdata/alpine-virt-3.17.0-x86_64.iso # to be removed from the repo. Add a target to enforce that the CI system # has copied that file into place before the tests run ci: xoa/testdata/alpine-virt-3.17.0-x86_64.iso - TF_ACC_TERRAFORM_PATH=/opt/terraform-provider-xenorchestra/bin/$(TF_VERSION) TF_ACC=1 gotestsum --debug --rerun-fails=5 --max-fails=15 --packages=./xoa -- ./xoa -v -count=1 -timeout=$(TIMEOUT) -sweep=true -parallel=$(GOMAXPROCS) -run TestAccXenorchestraDataSource_hostXoTokenAuth + TF_LOG=INFO TF_ACC_TERRAFORM_PATH=/opt/terraform-provider-xenorchestra/bin/$(TF_VERSION) TF_ACC=1 gotestsum --debug --rerun-fails=5 --max-fails=15 --packages=./xoa -- ./xoa -v -count=1 -timeout=$(TIMEOUT) -sweep=true -parallel=$(GOMAXPROCS) -run TestAccXenorchestraDataSource_hostXoTokenAuth diff --git a/client/client.go b/client/client.go index 928e115..c9024c0 100644 --- a/client/client.go +++ b/client/client.go @@ -325,7 +325,7 @@ func (c *Client) Call(method string, params, result interface{}) error { } else { callRes = reflect.ValueOf(result).Elem() } - log.Printf("[TRACE] Made rpc call `%s` with params: %v and received %+v: result with error: %v\n", method, params, callRes, err) + log.Printf("[INFO] Made rpc call `%s` with params: %v and received %+v: result with error: %v\n", method, params, callRes, err) if err != nil { rpcErr, ok := err.(*jsonrpc2.Error) diff --git a/xoa/acc_setup_test.go b/xoa/acc_setup_test.go index e674f79..85879b1 100644 --- a/xoa/acc_setup_test.go +++ b/xoa/acc_setup_test.go @@ -25,7 +25,6 @@ var disklessTestTemplate client.Template var testIso client.VDI func TestMain(m *testing.M) { - fmt.Printf("Found token of len=%d\n", len(accTestXoToken)) // This leverages the existing flag defined in the terraform-plugin-sdk // repo defined below // https://github.com/hashicorp/terraform-plugin-sdk/blob/2c03a32a9d1be63a12eb18aaf12d2c5270c42346/helper/resource/testing.go#L58