File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -66,8 +66,8 @@ def __init__(self,
66
66
if display_name :
67
67
service_name = display_name .replace (' ' , '_' ).lower ()
68
68
config = read_from_env_variables (service_name )
69
- if config .get ('url ' ):
70
- self .url = config .get ('url ' )
69
+ if config .get ('service_url ' ):
70
+ self .service_url = config .get ('service_url ' )
71
71
if config .get ('disable_ssl' ):
72
72
self .disable_ssl_verification = config .get ('disable_ssl' )
73
73
Original file line number Diff line number Diff line change @@ -139,12 +139,12 @@ def test_iam():
139
139
file_path = os .path .join (
140
140
os .path .dirname (__file__ ), '../resources/ibm-credentials-iam.env' )
141
141
os .environ ['IBM_CREDENTIALS_FILE' ] = file_path
142
- os .environ ['WATSON_URL ' ] = 'https://gateway-s.watsonplatform.net/watson/api'
142
+ os .environ ['WATSON_SERVICE_URL ' ] = 'https://gateway-s.watsonplatform.net/watson/api'
143
143
os .environ ['WATSON_DISABLE_SSL' ] = 'False'
144
144
service = AnyServiceV1 ('2017-07-07' , authenticator = iam_authenticator )
145
- assert service .url == 'https://gateway-s.watsonplatform.net/watson/api'
145
+ assert service .service_url == 'https://gateway-s.watsonplatform.net/watson/api'
146
146
del os .environ ['IBM_CREDENTIALS_FILE' ]
147
- del os .environ ['WATSON_URL ' ]
147
+ del os .environ ['WATSON_SERVICE_URL ' ]
148
148
del os .environ ['WATSON_DISABLE_SSL' ]
149
149
assert service .authenticator is not None
150
150
@@ -162,7 +162,7 @@ def test_iam():
162
162
status = 200 )
163
163
responses .add (
164
164
responses .GET ,
165
- url = 'https://gateway.watsonplatform.net/test /api' ,
165
+ url = 'https://gateway-s .watsonplatform.net/watson /api' ,
166
166
body = json .dumps ({
167
167
"foobar" : "baz"
168
168
}),
You can’t perform that action at this time.
0 commit comments