2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
21 // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
22 // See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
23 // Any modifications to this file will be lost upon recompilation of the source schema.
24 // Generated on: 2015.10.28 at 05:53:17 PM EDT
27 package org.onap.aai.domain.restResponseInfo;
29 import org.junit.Test;
31 import java.util.List;
33 import static org.junit.Assert.assertTrue;
35 public class InfoTest {
36 private Info info = new Info();
39 public void infoTest() {
40 Info.ResponseMessages responseMessages = info.getResponseMessages();
41 if (responseMessages == null) responseMessages = new Info.ResponseMessages();
43 List<Info.ResponseMessages.ResponseMessage> list = responseMessages.getResponseMessage();
44 Info.ResponseMessages.ResponseMessage respMsg = new Info.ResponseMessages.ResponseMessage();
46 respMsg.setMessageId("1");
47 respMsg.setText("textValue");
49 Info.ResponseMessages.ResponseMessage.Variables vars = new Info.ResponseMessages.ResponseMessage.Variables();
50 vars.getVariable().add("var1");
51 vars.getVariable().add("var2");
53 respMsg.setVariables(vars);
55 info.setResponseMessages(responseMessages);
57 Info.ResponseMessages responseMessages1 = info.getResponseMessages();
58 List<Info.ResponseMessages.ResponseMessage> list1 = responseMessages1.getResponseMessage();
59 Info.ResponseMessages.ResponseMessage respMsg1 = list1.get(0);
60 assertTrue(respMsg1.getMessageId().equals("1"));
61 assertTrue(respMsg1.getText().equals("textValue"));
62 assertTrue(respMsg1.getVariables().getVariable().contains("var1"));
63 assertTrue(respMsg1.getVariables().getVariable().contains("var2"));