@@ -28,13 +28,13 @@ def test_02_stack_region(self):
2828 self .assertEqual ('eu-cdn.contentstack.com' , stack_region .host )
2929
3030 def test_03_stack_endpoint (self ):
31- self .assertEqual (f"https://{ config .host } /v3" ,
31+ self .assertEqual (f"https://{ config .HOST } /v3" ,
3232 self .stack .endpoint )
3333
3434 def test_04_permission_error_api_key (self ):
3535 try :
3636 stack_local = contentstack .Stack (
37- '' , config .delivery_token , config .environment )
37+ '' , config .DELIVERYTOKEN , config .ENVIRONMENT )
3838 self .assertEqual (None , stack_local .api_key )
3939 except PermissionError as e :
4040 if hasattr (e , 'message' ):
@@ -43,7 +43,7 @@ def test_04_permission_error_api_key(self):
4343
4444 def test_05_permission_error_delivery_token (self ):
4545 try :
46- stack = contentstack .Stack (config .api_key , '' , config .environment )
46+ stack = contentstack .Stack (config .APIKEY , '' , config .ENVIRONMENT )
4747 self .assertEqual (None , stack .delivery_token )
4848 except PermissionError as e :
4949 if hasattr (e , 'message' ):
@@ -53,7 +53,7 @@ def test_05_permission_error_delivery_token(self):
5353 def test_05_permission_error_environment (self ):
5454 try :
5555 stack = contentstack .Stack (
56- config .api_key , config .delivery_token , '' )
56+ config .APIKEY , config .DELIVERYTOKEN , '' )
5757 self .assertEqual (None , stack .delivery_token )
5858 except PermissionError as e :
5959 if hasattr (e , 'message' ):
@@ -62,22 +62,22 @@ def test_05_permission_error_environment(self):
6262
6363 def test_07_get_api_key (self ):
6464 stack = contentstack .Stack (
65- config .api_key , config .delivery_token , config .environment )
66- self .assertEqual (config .api_key , stack .get_api_key )
65+ config .APIKEY , config .DELIVERYTOKEN , config .ENVIRONMENT )
66+ self .assertEqual (config .APIKEY , stack .get_api_key )
6767
6868 def test_08_get_delivery_token (self ):
6969 stack = contentstack .Stack (
70- config .api_key , config .delivery_token , config .environment )
71- self .assertEqual (config .delivery_token , stack .get_delivery_token )
70+ config .APIKEY , config .DELIVERYTOKEN , config .ENVIRONMENT )
71+ self .assertEqual (config .DELIVERYTOKEN , stack .get_delivery_token )
7272
7373 def test_09_get_environment (self ):
7474 stack = contentstack .Stack (
75- config .api_key , config .delivery_token , config .environment )
76- self .assertEqual (config .environment , stack .get_environment )
75+ config .APIKEY , config .DELIVERYTOKEN , config .ENVIRONMENT )
76+ self .assertEqual (config .ENVIRONMENT , stack .get_environment )
7777
7878 def test_10_get_headers (self ):
7979 stack = contentstack .Stack (
80- config .api_key , config .delivery_token , config .environment )
80+ config .APIKEY , config .DELIVERYTOKEN , config .ENVIRONMENT )
8181 self .assertEqual (True , 'api_key' in stack .headers )
8282 self .assertEqual (True , 'access_token' in stack .get_headers )
8383 self .assertEqual (True , 'environment' in stack .get_headers )
@@ -163,7 +163,7 @@ def test_21_content_type(self):
163163 def test_check_region (self ):
164164 """_summary_
165165 """
166- _stack = contentstack .Stack (config .api_key , config .delivery_token , config .environment ,
167- host = config .host , region = ContentstackRegion .AZURE_NA )
166+ _stack = contentstack .Stack (config .APIKEY , config .DELIVERYTOKEN , config .ENVIRONMENT ,
167+ host = config .HOST , region = ContentstackRegion .AZURE_NA )
168168 var = _stack .region .value
169169 self .assertEqual ('azure-na' , var )
0 commit comments