// ÄK 2 @Test public void testReferrerEmpty() { response = requestConnector.GetContentFromAmazon("http://sqat.eu-gb.mybluemix.net", "", agent); assertTrue( response.containsKey(expectedProductName) && response.get(expectedProductName).equals(expectedProductPrice)); }
// ÄK 1 @Test(expected = IllegalArgumentException.class) public void testReferrerNull() { response = requestConnector.GetContentFromAmazon("http://sqat.eu-gb.mybluemix.net", null, agent); }
// ÄK 4 @Test public void testStringValidURL() { response = requestConnector.GetContentFromAmazon("http://google.de", "Test", agent); HashMap<String, String> expected = new HashMap<String, String>(); assertEquals(expected, response); }
// ÄK 3 @Test(expected = IllegalArgumentException.class) public void testStringNotValidURL() { response = requestConnector.GetContentFromAmazon("Zeichenkette, keine URL", "Test", agent); }
// ÄK 2 @Test(expected = IllegalArgumentException.class) public void testStringEmpty() { response = requestConnector.GetContentFromAmazon("", "Test", agent); }
// build testserver response public HashMap<String, String> buildTestserverResponse(GenericAgent agent) { return requestConnector.GetContentFromAmazon("http://sqat.eu-gb.mybluemix.net", "Test", agent); }