blob: 0574cec177d0ec125953a86ec12c5c494bfd13a0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
package org.onap.vid.api;
import java.util.HashMap;
import org.junit.Assert;
import org.springframework.core.ParameterizedTypeReference;
import org.springframework.http.ResponseEntity;
import org.testng.annotations.Test;
import vid.automation.test.utils.InsecureHttpsClient;
public class VersionControllerApiTest extends BaseApiTest {
@Test
public void probeRequest_returnsResponseAsExpected() {
// without log-in
ResponseEntity<HashMap<String, String>> response = InsecureHttpsClient.newRestTemplate().exchange(
uri + "/version",
org.springframework.http.HttpMethod.GET,
null,
new ParameterizedTypeReference<HashMap<String, String>>() {
});
HashMap<String,String> versionResults = response.getBody();
Assert.assertNotNull(versionResults.get("features"));
Assert.assertNotNull(versionResults.get("build"));
}
}
|