1 package org.openecomp.vid.controller;
3 import javax.servlet.http.HttpServletRequest;
5 import org.json.simple.JSONObject;
7 import org.springframework.http.ResponseEntity;
8 import org.springframework.web.servlet.ModelAndView;
10 public class AaiControllerTest {
12 private AaiController createTestSubject() {
13 return new AaiController();
17 public void testParseCustomerObjectForTenants() throws Exception {
18 JSONObject jsonObject = null;
22 result = AaiController.parseCustomerObjectForTenants(jsonObject);
26 public void testParseServiceSubscriptionObjectForTenants() throws Exception {
27 JSONObject jsonObject = null;
31 result = AaiController.parseServiceSubscriptionObjectForTenants(jsonObject);
35 public void testWelcome() throws Exception {
36 AaiController testSubject;
37 HttpServletRequest request = null;
41 testSubject = createTestSubject();
42 result = testSubject.welcome(request);
46 public void testGetViewName() throws Exception {
47 AaiController testSubject;
51 testSubject = createTestSubject();
52 result = testSubject.getViewName();
56 public void testSetViewName() throws Exception {
57 AaiController testSubject;
61 testSubject = createTestSubject();
62 testSubject.setViewName(viewName);
66 public void testGetTargetProvStatus() throws Exception {
67 AaiController testSubject;
68 ResponseEntity<String> result;
71 testSubject = createTestSubject();
72 result = testSubject.getTargetProvStatus();
76 public void testViewEditGetTenantsFromServiceType() throws Exception {
77 AaiController testSubject;
78 HttpServletRequest request = null;
79 String globalCustomerId = "";
80 String serviceType = "";
81 ResponseEntity<String> result;
84 testSubject = createTestSubject();
85 result = testSubject.viewEditGetTenantsFromServiceType(request, globalCustomerId, serviceType);