| 1 | package scwscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ |
| 2 | |
| 3 | import ( |
| 4 | "osscip-go gomod github.com/golang/go/src go1.17 os/" |
| 5 | "stringsscip-go gomod github.com/golang/go/src go1.17 strings/" |
| 6 | "testingscip-go gomod github.com/golang/go/src go1.17 testing/" |
| 7 | |
| 8 | "github.com/scaleway/scaleway-sdk-go/internal/authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/" |
| 9 | "github.com/scaleway/scaleway-sdk-go/internal/testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/" |
| 10 | ) |
| 11 | |
| 12 | var ( |
| 13 | defaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultOrganizationID. = "6170692e-7363-616c-6577-61792e636f6d" // hint: | xxd -ps -r |
| 14 | defaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultProjectID. = "6170692e-7363-616c-6577-61792e636f6d" // hint: | xxd -ps -r |
| 15 | defaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultRegion. = RegionNlAmsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/RegionNlAms. |
| 16 | defaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultZone. = ZoneNlAms1scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ZoneNlAms1. |
| 17 | ) |
| 18 | |
| 19 | func TestClientOptionsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/TestClientOptions().(t *testingscip-go gomod github.com/golang/go/src go1.17 testing/.Tscip-go gomod github.com/golang/go/src go1.17 testing/T#) { |
| 20 | testCases := []struct { |
| 21 | name string |
| 22 | clientOption ClientOptionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ClientOption# |
| 23 | errStr string |
| 24 | }{ |
| 25 | { |
| 26 | name: "Create a valid client option", |
| 27 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 28 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 29 | s.apiURLscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#apiURL. = v2ValidAPIURLscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAPIURL. |
| 30 | s.defaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultOrganizationID. = &defaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultOrganizationID. |
| 31 | s.defaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultProjectID. = &defaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultProjectID. |
| 32 | s.defaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultRegion. = &defaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultRegion. |
| 33 | s.defaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultZone. = &defaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/defaultZone. |
| 34 | }, |
| 35 | }, |
| 36 | { |
| 37 | name: "Should throw an empty access key error", |
| 38 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 39 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().("", v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 40 | }, |
| 41 | errStr: "scaleway-sdk-go: access key cannot be empty", |
| 42 | }, |
| 43 | { |
| 44 | name: "Should throw a bad access key error", |
| 45 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 46 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2InvalidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2InvalidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 47 | }, |
| 48 | errStr: "scaleway-sdk-go: invalid access key format 'invalid', expected SCWXXXXXXXXXXXXXXXXX format", |
| 49 | }, |
| 50 | { |
| 51 | name: "Should throw an empty secret key error", |
| 52 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 53 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., "") |
| 54 | }, |
| 55 | errStr: "scaleway-sdk-go: secret key cannot be empty", |
| 56 | }, |
| 57 | { |
| 58 | name: "Should throw a bad secret key error", |
| 59 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 60 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2InvalidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2InvalidSecretKey.) |
| 61 | }, |
| 62 | errStr: "scaleway-sdk-go: invalid secret key format 'invalid', expected a UUID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", |
| 63 | }, |
| 64 | { |
| 65 | name: "Should throw an url error", |
| 66 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 67 | s.apiURLscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#apiURL. = ":test" |
| 68 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 69 | }, |
| 70 | errStr: "scaleway-sdk-go: invalid url :test", |
| 71 | }, |
| 72 | { |
| 73 | name: "Should throw an empty organization ID error", |
| 74 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 75 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 76 | s.defaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultOrganizationID. = StringPtrscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/StringPtr().("") |
| 77 | }, |
| 78 | errStr: "scaleway-sdk-go: default organization ID cannot be empty", |
| 79 | }, |
| 80 | { |
| 81 | name: "Should throw a bad organization ID error", |
| 82 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 83 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 84 | s.defaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultOrganizationID. = StringPtrscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/StringPtr().(v2InvalidDefaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2InvalidDefaultOrganizationID.) |
| 85 | }, |
| 86 | errStr: "scaleway-sdk-go: invalid organization ID format 'invalid', expected a UUID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", |
| 87 | }, |
| 88 | { |
| 89 | name: "Should throw an empty project ID error", |
| 90 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 91 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 92 | s.defaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultProjectID. = StringPtrscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/StringPtr().("") |
| 93 | }, |
| 94 | errStr: "scaleway-sdk-go: default project ID cannot be empty", |
| 95 | }, |
| 96 | { |
| 97 | name: "Should throw a bad project ID error", |
| 98 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 99 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey.) |
| 100 | s.defaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultProjectID. = StringPtrscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/StringPtr().(v2InvalidDefaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2InvalidDefaultProjectID.) |
| 101 | }, |
| 102 | errStr: "scaleway-sdk-go: invalid project ID format 'invalid', expected a UUID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", |
| 103 | }, |
| 104 | { |
| 105 | name: "Should throw a region error", |
| 106 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 107 | v := Regionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Region#("") |
| 108 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(testAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testAccessKey., testSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testSecretKey.) |
| 109 | s.defaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultRegion. = &v |
| 110 | }, |
| 111 | errStr: "scaleway-sdk-go: default region cannot be empty", |
| 112 | }, |
| 113 | { |
| 114 | name: "Should throw a bad region error", |
| 115 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 116 | v := Regionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Region#(v2InvalidDefaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2InvalidDefaultRegion.) |
| 117 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(testAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testAccessKey., testSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testSecretKey.) |
| 118 | s.defaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultRegion. = &v |
| 119 | }, |
| 120 | errStr: "scaleway-sdk-go: invalid default region format 'invalid', available regions are: fr-par, nl-ams, pl-waw", |
| 121 | }, |
| 122 | { |
| 123 | name: "Should throw a zone error", |
| 124 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 125 | v := Zonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Zone#("") |
| 126 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(testAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testAccessKey., testSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testSecretKey.) |
| 127 | s.defaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultZone. = &v |
| 128 | }, |
| 129 | errStr: "scaleway-sdk-go: default zone cannot be empty", |
| 130 | }, |
| 131 | { |
| 132 | name: "Should throw a bad zone error", |
| 133 | clientOption: func(s *settingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#) { |
| 134 | v := Zonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Zone#(v2InvalidDefaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2InvalidDefaultZone.) |
| 135 | s.tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#token. = authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.NewTokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/NewToken().(testAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testAccessKey., testSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/testSecretKey.) |
| 136 | s.defaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#defaultZone. = &v |
| 137 | }, |
| 138 | errStr: "scaleway-sdk-go: invalid default zone format 'invalid', available zones are: fr-par-1, fr-par-2, fr-par-3, nl-ams-1, nl-ams-2, nl-ams-3, pl-waw-1, pl-waw-2, pl-waw-3", |
| 139 | }, |
| 140 | } |
| 141 | |
| 142 | for _, c := range testCases { |
| 143 | t.Runscip-go gomod github.com/golang/go/src go1.17 testing/T#Run().(c.name, func(t *testingscip-go gomod github.com/golang/go/src go1.17 testing/.Tscip-go gomod github.com/golang/go/src go1.17 testing/T#) { |
| 144 | // New |
| 145 | s := newSettingsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/newSettings().() |
| 146 | |
| 147 | // Apply |
| 148 | s.applyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#apply().([]ClientOptionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ClientOption#{c.clientOption}) |
| 149 | |
| 150 | // Validate |
| 151 | err := s.validatescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/settings#validate().() |
| 152 | |
| 153 | if c.errStr != "" { |
| 154 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Assertscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Assert().(t, err != nil, "Should have error") |
| 155 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, c.errStr, err.Error()) |
| 156 | } else { |
| 157 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.AssertNoErrorscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/AssertNoError().(t, err) |
| 158 | } |
| 159 | }) |
| 160 | } |
| 161 | } |
| 162 | |
| 163 | func TestCombinedClientOptionsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/TestCombinedClientOptions().(t *testingscip-go gomod github.com/golang/go/src go1.17 testing/.Tscip-go gomod github.com/golang/go/src go1.17 testing/T#) { |
| 164 | tests := []struct { |
| 165 | name string |
| 166 | env map[string]string |
| 167 | files map[string]string |
| 168 | |
| 169 | expectedError string |
| 170 | expectedAccessKey string |
| 171 | expectedSecretKey string |
| 172 | expectedAPIURL string |
| 173 | expectedDefaultOrganizationID *string |
| 174 | expectedDefaultProjectID *string |
| 175 | expectedDefaultRegion *Regionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Region# |
| 176 | expectedDefaultZone *Zonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Zone# |
| 177 | }{ |
| 178 | { |
| 179 | name: "Complete config file with env variables", |
| 180 | env: map[string]string{ |
| 181 | "HOME": "{HOME}", |
| 182 | ScwAccessKeyEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwAccessKeyEnv.: v2ValidAccessKey2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey2., |
| 183 | ScwSecretKeyEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwSecretKeyEnv.: v2ValidSecretKey2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey2., |
| 184 | ScwAPIURLEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwAPIURLEnv.: v2ValidAPIURL2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAPIURL2., |
| 185 | ScwDefaultOrganizationIDEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultOrganizationIDEnv.: v2ValidDefaultOrganizationID2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultOrganizationID2., |
| 186 | ScwDefaultProjectIDEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultProjectIDEnv.: v2ValidDefaultProjectID2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultProjectID2., |
| 187 | ScwDefaultRegionEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultRegionEnv.: v2ValidDefaultRegion2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultRegion2., |
| 188 | ScwDefaultZoneEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultZoneEnv.: v2ValidDefaultZone2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultZone2., |
| 189 | }, |
| 190 | files: map[string]string{ |
| 191 | ".config/scw/config.yaml": v2CompleteValidConfigFilescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2CompleteValidConfigFile., |
| 192 | }, |
| 193 | expectedAccessKey: v2ValidAccessKey2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey2., |
| 194 | expectedSecretKey: v2ValidSecretKey2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey2., |
| 195 | expectedAPIURL: v2ValidAPIURL2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAPIURL2., |
| 196 | expectedDefaultOrganizationID: sscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/s().(v2ValidDefaultOrganizationID2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultOrganizationID2.), |
| 197 | expectedDefaultProjectID: sscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/s().(v2ValidDefaultProjectID2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultProjectID2.), |
| 198 | expectedDefaultRegion: rscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/r().(Regionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Region#(v2ValidDefaultRegion2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultRegion2.)), |
| 199 | expectedDefaultZone: zscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/z().(Zonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Zone#(v2ValidDefaultZone2scip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultZone2.)), |
| 200 | }, |
| 201 | { |
| 202 | name: "Complete config with active profile env variable and all env variables", |
| 203 | env: map[string]string{ |
| 204 | "HOME": "{HOME}", |
| 205 | ScwActiveProfileEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwActiveProfileEnv.: v2ValidProfilescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidProfile., |
| 206 | ScwAccessKeyEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwAccessKeyEnv.: v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., |
| 207 | ScwSecretKeyEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwSecretKeyEnv.: v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey., |
| 208 | ScwAPIURLEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwAPIURLEnv.: v2ValidAPIURLscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAPIURL., |
| 209 | ScwDefaultOrganizationIDEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultOrganizationIDEnv.: v2ValidDefaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultOrganizationID., |
| 210 | ScwDefaultProjectIDEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultProjectIDEnv.: v2ValidDefaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultProjectID., |
| 211 | ScwDefaultRegionEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultRegionEnv.: v2ValidDefaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultRegion., |
| 212 | ScwDefaultZoneEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/ScwDefaultZoneEnv.: v2ValidDefaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultZone., |
| 213 | }, |
| 214 | files: map[string]string{ |
| 215 | ".config/scw/config.yaml": v2CompleteValidConfigFilescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2CompleteValidConfigFile., |
| 216 | }, |
| 217 | expectedAccessKey: v2ValidAccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAccessKey., |
| 218 | expectedSecretKey: v2ValidSecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidSecretKey., |
| 219 | expectedAPIURL: v2ValidAPIURLscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidAPIURL., |
| 220 | expectedDefaultOrganizationID: sscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/s().(v2ValidDefaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultOrganizationID.), |
| 221 | expectedDefaultProjectID: sscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/s().(v2ValidDefaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultProjectID.), |
| 222 | expectedDefaultRegion: rscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/r().(Regionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Region#(v2ValidDefaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultRegion.)), |
| 223 | expectedDefaultZone: zscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/z().(Zonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Zone#(v2ValidDefaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/v2ValidDefaultZone.)), |
| 224 | }, |
| 225 | } |
| 226 | |
| 227 | // create home dir |
| 228 | dir := initEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/initEnv().(t) |
| 229 | |
| 230 | // delete home dir and reset env variables |
| 231 | defer resetEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/resetEnv().(t, osscip-go gomod github.com/golang/go/src go1.17 os/.Environscip-go gomod github.com/golang/go/src go1.17 os/Environ().(), dir) |
| 232 | for _, test := range tests { |
| 233 | t.Runscip-go gomod github.com/golang/go/src go1.17 testing/T#Run().(test.name, func(t *testingscip-go gomod github.com/golang/go/src go1.17 testing/.Tscip-go gomod github.com/golang/go/src go1.17 testing/T#) { |
| 234 | // set up env and config file(s) |
| 235 | setEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/setEnv().(t, test.env, test.files, dir) |
| 236 | test.expectedError = stringsscip-go gomod github.com/golang/go/src go1.17 strings/.ReplaceAllscip-go gomod github.com/golang/go/src go1.17 strings/ReplaceAll().(test.expectedError, "{HOME}", dir) |
| 237 | |
| 238 | // remove config file(s) |
| 239 | defer cleanEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/cleanEnv().(t, test.files, dir) |
| 240 | |
| 241 | config, err := LoadConfigscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/LoadConfig().() |
| 242 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.AssertNoErrorscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/AssertNoError().(t, err) |
| 243 | |
| 244 | p, err := config.GetActiveProfilescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Config#GetActiveProfile().() |
| 245 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.AssertNoErrorscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/AssertNoError().(t, err) |
| 246 | |
| 247 | client, err := NewClientscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/NewClient().(WithProfilescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/WithProfile().(p), WithEnvscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/WithEnv().()) |
| 248 | if test.expectedError == "" { |
| 249 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.AssertNoErrorscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/AssertNoError().(t, err) |
| 250 | |
| 251 | // assert getters |
| 252 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedAccessKey, client.authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#auth..(*authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.Tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/Token#).AccessKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/Token#AccessKey.) |
| 253 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedSecretKey, client.authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#auth..(*authscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/.Tokenscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/Token#).SecretKeyscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/auth`/Token#SecretKey.) |
| 254 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedAPIURL, client.apiURLscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#apiURL.) |
| 255 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedDefaultOrganizationID, client.defaultOrganizationIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#defaultOrganizationID.) |
| 256 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedDefaultProjectID, client.defaultProjectIDscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#defaultProjectID.) |
| 257 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedDefaultRegion, client.defaultRegionscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#defaultRegion.) |
| 258 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedDefaultZone, client.defaultZonescip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/scw`/Client#defaultZone.) |
| 259 | // skip insecure tests |
| 260 | } else { |
| 261 | testhelpersscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/.Equalsscip-go gomod github.com/scaleway/scaleway-sdk-go . `github.com/scaleway/scaleway-sdk-go/internal/testhelpers`/Equals().(t, test.expectedError, err.Error()) |
| 262 | } |
| 263 | }) |
| 264 | } |
| 265 | } |