File tree Expand file tree Collapse file tree 1 file changed +0
-23
lines changed
Expand file tree Collapse file tree 1 file changed +0
-23
lines changed Original file line number Diff line number Diff line change 11package gitlab
22
33import (
4- "errors"
54 "os"
6- "strings"
75 "testing"
86
97 "github.com/hashicorp/terraform-plugin-sdk/helper/schema"
108 "github.com/hashicorp/terraform-plugin-sdk/terraform"
11- "github.com/xanzy/go-gitlab"
129)
1310
1411var testAccProviders map [string ]terraform.ResourceProvider
@@ -21,26 +18,6 @@ func init() {
2118 }
2219}
2320
24- func isRunningInEE () (bool , error ) {
25- if conn , ok := testAccProvider .Meta ().(* gitlab.Client ); ok {
26- version , _ , err := conn .Version .GetVersion ()
27- if err != nil {
28- return false , err
29- }
30- if strings .Contains (version .String (), "-ee" ) {
31- return true , nil
32- }
33- } else {
34- return false , errors .New ("Provider not initialized, unable to get GitLab connection" )
35- }
36- return false , nil
37- }
38-
39- func isRunningInCE () (bool , error ) {
40- isEE , err := isRunningInEE ()
41- return ! isEE , err
42- }
43-
4421func TestProvider (t * testing.T ) {
4522 if err := Provider ().(* schema.Provider ).InternalValidate (); err != nil {
4623 t .Fatalf ("err: %s" , err )
You can’t perform that action at this time.
0 commit comments