File tree Expand file tree Collapse file tree 2 files changed +2
-16
lines changed
Expand file tree Collapse file tree 2 files changed +2
-16
lines changed Original file line number Diff line number Diff line change @@ -63,15 +63,6 @@ def __init__(self,
6363 raise ValueError (
6464 'authenticator should be of type Authenticator' )
6565
66- if display_name :
67- service_name = display_name .replace (' ' , '_' ).replace ('-' , '_' ).lower ()
68- config = read_external_sources (service_name )
69- if config .get ('url' ):
70- self .service_url = config .get ('url' )
71- if config .get ('disable_ssl' ):
72- self .disable_ssl_verification = config .get ('disable_ssl' )
73-
74-
7566 def _get_system_info (self ):
7667 return '{0} {1} {2}' .format (
7768 platform .system (), # OS
Original file line number Diff line number Diff line change @@ -140,7 +140,7 @@ def test_iam():
140140 os .path .dirname (__file__ ), '../resources/ibm-credentials-iam.env' )
141141 os .environ ['IBM_CREDENTIALS_FILE' ] = file_path
142142 service = AnyServiceV1 ('2017-07-07' , authenticator = iam_authenticator )
143- assert service .service_url == 'https://gateway-s .watsonplatform.net/watson /api'
143+ assert service .service_url == 'https://gateway.watsonplatform.net/test /api'
144144 del os .environ ['IBM_CREDENTIALS_FILE' ]
145145 assert service .authenticator is not None
146146
@@ -158,7 +158,7 @@ def test_iam():
158158 status = 200 )
159159 responses .add (
160160 responses .GET ,
161- url = 'https://gateway-s .watsonplatform.net/watson /api' ,
161+ url = 'https://gateway.watsonplatform.net/test /api' ,
162162 body = json .dumps ({
163163 "foobar" : "baz"
164164 }),
@@ -422,8 +422,3 @@ def test_service_url_not_set():
422422 with pytest .raises (ValueError ) as err :
423423 service .prepare_request ('POST' , url = '' )
424424 assert str (err .value ) == 'The service_url is required'
425-
426- def test_multi_word_service_name ():
427- os .environ ['personality-insights_url' ] = 'xyz'
428- service = BaseService (service_url = '' , authenticator = NoAuthAuthenticator (), display_name = 'personality-insights' )
429- assert service .service_url == 'xyz'
You can’t perform that action at this time.
0 commit comments