5292521b290dbebeb26afeaad62e5107b021bcb7
[sdc/sdc-workflow-designer.git] /
1 /**\r
2  * Copyright (c) 2018 ZTE Corporation.\r
3  * All rights reserved. This program and the accompanying materials\r
4  * are made available under the Apache License, Version 2.0\r
5  * and the Eclipse Public License v1.0 which both accompany this distribution,\r
6  * and are available at http://www.eclipse.org/legal/epl-v10.html\r
7  * and http://www.apache.org/licenses/LICENSE-2.0\r
8  *\r
9  * Contributors:\r
10  *     ZTE - initial API and implementation and/or initial documentation\r
11  */\r
12 package org.onap.sdc.workflowdesigner.utils.entity;\r
13 \r
14 import static org.junit.Assert.*;\r
15 \r
16 import org.junit.After;\r
17 import org.junit.Before;\r
18 import org.junit.Test;\r
19 \r
20 /**\r
21  *\r
22  */\r
23 public class CommonErrorResponseTest {\r
24 \r
25   /**\r
26    * @throws java.lang.Exception\r
27    */\r
28   @Before\r
29   public void setUp() throws Exception {}\r
30 \r
31   /**\r
32    * @throws java.lang.Exception\r
33    */\r
34   @After\r
35   public void tearDown() throws Exception {}\r
36 \r
37   /**\r
38    * Test method for {@link org.onap.sdc.workflowdesigner.utils.entity.CommonErrorResponse#failure(java.lang.String)}.\r
39    */\r
40   @Test\r
41   public void testFailure() {\r
42     String code = "code";\r
43     String message = "message";\r
44     CommonErrorResponse errorResponse = new CommonErrorResponse(code);\r
45     errorResponse.setCode(code);\r
46     errorResponse.setMessage(message);\r
47     assertEquals(code, errorResponse.getCode());\r
48     assertEquals(message, errorResponse.getMessage());\r
49   }\r
50 \r
51 }\r