File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -6,17 +6,17 @@ class ApiTesting():
66
77 # Make GET request
88 @classmethod
9- def get_request (self ):
10- request_url = self .default_url
9+ def get_request (cls ):
10+ request_url = cls .default_url
1111 input_url = input ('Enter URL: ' )
1212 if input_url != '' :
1313 request_url = input_url
1414
1515 # Check whether the request_url has an endpoint or not
16- has_endpoint = self .__check_endpoint (request_url )
16+ has_endpoint = cls .__check_endpoint (request_url )
1717
1818 # Check if http:// or https:// is present in request_url
19- has_protocol = self .__check_protocol (request_url )
19+ has_protocol = cls .__check_protocol (request_url )
2020
2121 if not (has_protocol ):
2222 request_url = "https://" + request_url
@@ -52,14 +52,14 @@ def get_request(self):
5252 print (e )
5353
5454 @classmethod
55- def __check_endpoint (self , request_url ):
56- if (request_url == self .default_url ):
55+ def __check_endpoint (cls , request_url ):
56+ if (request_url == cls .default_url ):
5757 return False
5858 else :
5959 return True
6060
6161 @classmethod
62- def __check_protocol (self , request_url ):
62+ def __check_protocol (cls , request_url ):
6363 if (request_url [:4 ] == 'http' ):
6464 return True
6565 else :
You can’t perform that action at this time.
0 commit comments