How to check if the response of https url / links | Selenium Forum
M
Posted on 05/06/2016
Hi,

My objective of the test is to check if the URL links (which is https) response is Okie (200) or NOT after loading the main site (https) url

For this what I am doing is, Loading the Chrome Browser as (Attached 1)

When I do using above code, I am seeing https as disabled (Cross Marked in the Browser) ?

And I go inside the Page and travers for the Link and Check the Reponse of the Links

public static boolean checkResponse(String Url) {
try {
int rescode = Request.Get(Url).execute().returnResponse().getStatusLine().getStatusCode();
System.out.println("The Response Code for " + WebUrl + " Is -> " + rescode);
if (rescode==200)
return true;
else
return false;
} catch (Exception e) {
return false;
}
}


I am getting SSL Handshake certificate error, I feel like since https is disabled upon load.. this is the causing the error


Appreciate if could provide solution for this.... how to check the response for the https url (with or without enabling or disabling...)

Thanks

Regards
J

M
Replied on 06/06/2016

could you wait till tommorow i'll show this to ashish.


M
Replied on 06/06/2016

Sure, to get perfect solution for this I can wait...

Thanks

Regards
J


M
Replied on 07/06/2016

Any update for the below request ?


M
Replied on 12/06/2016

His site is not having a valid certificate
Ask him if company can get valid certificate