@@ -207,47 +207,30 @@ func TestBuilder(t *testing.T) {
207
207
name : "Sfn service with HTTP client settings" ,
208
208
fn : func (t * testing.T ) {
209
209
sfnSvc , err := builder .NewSFNService (c , "default" )
210
+
211
+ // SFN service does not have access to options for now
210
212
assert .NoError (t , err )
211
213
assert .NotNil (t , sfnSvc )
212
-
213
- opts := sfnSvc .Options ()
214
- assert .Equal (t , opts .Region , "us-east-2" )
215
- assert .NotNil (t , opts .HTTPClient )
216
-
217
- httpTransport := opts .HTTPClient .(* http.Client ).Transport .(* http.Transport )
218
- assert .Equal (t , httpTransport .MaxIdleConnsPerHost , 100 )
219
214
},
220
215
},
221
216
{
222
217
name : "Sfn service with static credentials" ,
223
218
fn : func (t * testing.T ) {
224
219
sfnSvc , err := builder .NewSFNService (c , "test" )
220
+
221
+ // SFN service does not have access to options for now
225
222
assert .NoError (t , err )
226
223
assert .NotNil (t , sfnSvc )
227
-
228
- opts := sfnSvc .Options ()
229
- assert .Equal (t , opts .Region , "us-east-1" )
230
- assert .NotNil (t , opts .Credentials )
231
-
232
- creds := opts .Credentials .(credentials.StaticCredentialsProvider )
233
- assert .Equal (t , creds .Value .AccessKeyID , "test" )
234
- assert .Equal (t , creds .Value .SecretAccessKey , "test" )
235
- assert .Equal (t , creds .Value .SessionToken , "test" )
236
224
},
237
225
},
238
226
{
239
227
name : "Sfn service with assume role credentials" ,
240
228
fn : func (t * testing.T ) {
241
229
sfnSvc , err := builder .NewSFNService (c , "test2" )
230
+
231
+ // SFN service does not have access to options for now
242
232
assert .NoError (t , err )
243
233
assert .NotNil (t , sfnSvc )
244
-
245
- opts := sfnSvc .Options ()
246
- assert .Equal (t , opts .Region , "us-west-2" )
247
- assert .NotNil (t , opts .Credentials )
248
-
249
- creds := opts .Credentials .(* aws.CredentialsCache )
250
- assert .NotNil (t , creds )
251
234
},
252
235
},
253
236
{
@@ -262,47 +245,30 @@ func TestBuilder(t *testing.T) {
262
245
name : "Sqs service with HTTP client settings" ,
263
246
fn : func (t * testing.T ) {
264
247
sqsSvc , err := builder .NewSQSService (c , "default" )
248
+
249
+ // SQS service does not have access to options for now
265
250
assert .NoError (t , err )
266
251
assert .NotNil (t , sqsSvc )
267
-
268
- opts := sqsSvc .Options ()
269
- assert .Equal (t , opts .Region , "us-east-2" )
270
- assert .NotNil (t , opts .HTTPClient )
271
-
272
- httpTransport := opts .HTTPClient .(* http.Client ).Transport .(* http.Transport )
273
- assert .Equal (t , httpTransport .MaxIdleConnsPerHost , 100 )
274
252
},
275
253
},
276
254
{
277
255
name : "Sqs service with static credentials" ,
278
256
fn : func (t * testing.T ) {
279
257
sqsSvc , err := builder .NewSQSService (c , "test" )
258
+
259
+ // SQS service does not have access to options for now
280
260
assert .NoError (t , err )
281
261
assert .NotNil (t , sqsSvc )
282
-
283
- opts := sqsSvc .Options ()
284
- assert .Equal (t , opts .Region , "us-east-1" )
285
- assert .NotNil (t , opts .Credentials )
286
-
287
- creds := opts .Credentials .(credentials.StaticCredentialsProvider )
288
- assert .Equal (t , creds .Value .AccessKeyID , "test" )
289
- assert .Equal (t , creds .Value .SecretAccessKey , "test" )
290
- assert .Equal (t , creds .Value .SessionToken , "test" )
291
262
},
292
263
},
293
264
{
294
265
name : "Sqs service with assume role credentials" ,
295
266
fn : func (t * testing.T ) {
296
267
sqsSvc , err := builder .NewSQSService (c , "test2" )
268
+
269
+ // SQS service does not have access to options for now
297
270
assert .NoError (t , err )
298
271
assert .NotNil (t , sqsSvc )
299
-
300
- opts := sqsSvc .Options ()
301
- assert .Equal (t , opts .Region , "us-west-2" )
302
- assert .NotNil (t , opts .Credentials )
303
-
304
- creds := opts .Credentials .(* aws.CredentialsCache )
305
- assert .NotNil (t , creds )
306
272
},
307
273
},
308
274
{
0 commit comments