Added oparent to sdc main
[sdc.git] / common-app-api / src / test / java / org / openecomp / sdc / be / config / ErrorInfoTest.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * SDC
4  * ================================================================================
5  * Copyright (C) 2019 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
10  * 
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  * 
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=========================================================
19  */
20
21 package org.openecomp.sdc.be.config;
22
23 import org.junit.Test;
24 import org.openecomp.sdc.be.config.ErrorInfo.ErrorInfoType;
25
26
27 public class ErrorInfoTest {
28
29         private ErrorInfo createTestSubject() {
30                 return new ErrorInfo();
31         }
32
33         
34         @Test
35         public void testGetCode() throws Exception {
36                 ErrorInfo testSubject;
37                 Integer result;
38
39                 // default test
40                 testSubject = createTestSubject();
41                 result = testSubject.getCode();
42         }
43
44         
45         @Test
46         public void testSetCode() throws Exception {
47                 ErrorInfo testSubject;
48                 Integer code = 0;
49
50                 // default test
51                 testSubject = createTestSubject();
52                 testSubject.setCode(code);
53         }
54
55         
56         @Test
57         public void testGetMessage() throws Exception {
58                 ErrorInfo testSubject;
59                 String result;
60
61                 // default test
62                 testSubject = createTestSubject();
63                 result = testSubject.getMessage();
64         }
65
66         
67         @Test
68         public void testSetMessage() throws Exception {
69                 ErrorInfo testSubject;
70                 String message = "";
71
72                 // default test
73                 testSubject = createTestSubject();
74                 testSubject.setMessage(message);
75         }
76
77         
78         @Test
79         public void testGetMessageId() throws Exception {
80                 ErrorInfo testSubject;
81                 String result;
82
83                 // default test
84                 testSubject = createTestSubject();
85                 result = testSubject.getMessageId();
86         }
87
88         
89         @Test
90         public void testSetMessageId() throws Exception {
91                 ErrorInfo testSubject;
92                 String messageId = "";
93
94                 // test 1
95                 testSubject = createTestSubject();
96                 messageId = null;
97                 testSubject.setMessageId(messageId);
98
99                 // test 2
100                 testSubject = createTestSubject();
101                 messageId = "";
102                 testSubject.setMessageId(messageId);
103         }
104
105         
106         @Test
107         public void testGetErrorInfoType() throws Exception {
108                 ErrorInfo testSubject;
109                 ErrorInfoType result;
110
111                 // default test
112                 testSubject = createTestSubject();
113                 result = testSubject.getErrorInfoType();
114         }
115
116         
117
118         
119         @Test
120         public void testToString() throws Exception {
121                 ErrorInfo testSubject;
122                 String result;
123
124                 // default test
125                 testSubject = createTestSubject();
126                 result = testSubject.toString();
127         }
128 }