--
You received this message because you are subscribed to the Google Groups "REST assured" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rest-assured...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
PropertyFile propFile = PropertyFile.getInstance();
propFile.read("BrowserURL");
setUsername(propFile.read("CustomerUserName"));
setPassword(propFile.read("CustomerPassword"));
String serverName1 = propFile.read("RestUrl");
login();
System.out.println("Did the Cookie jar get there?");
given().auth().none().expect().statusCode(200).body(
"status", equalTo("ok")).
when().
get(serverName1+"/uriForREST/api/detail").asString();
}
public NavigationResult clickAndWaitForCookies(String
url, String timeout, String errorMessage) {
NavigationResult result = open("https://serverURL");
System.out.println("LoggedIn looking for cookies?");
Response response = given().get("https://serverUrl/context");
Map<String, String> allCookies = response.getCookies();
System.out.println("I think I got em?! : " +allCookies);
String sessionId = response.getSessionId();
RestAssured.sessionId = response.getSessionId();
System.out.println("Might Have got the sessionId too?! : " +sessionId);
return result;
}
--