Increasing test coverage
[aai/sparky-be.git] / src / test / java / org / onap / aai / sparky / subscription / payload / entity / ObjectInspectorPayloadTest.java
1 package org.onap.aai.sparky.subscription.payload.entity;
2
3 import static org.junit.Assert.assertNotNull;
4 import static org.junit.Assert.assertNull;
5
6 import java.io.IOException;
7
8 import org.junit.Before;
9 import org.junit.Test;
10 import org.onap.aai.sparky.subscription.config.SubscriptionConfig;
11
12 import com.fasterxml.jackson.core.JsonParseException;
13 import com.fasterxml.jackson.databind.JsonMappingException;
14
15 public class ObjectInspectorPayloadTest {
16         
17         private ObjectInspectorPayload objectInspectorPayload;
18         private Message  message; 
19
20         @Before
21           public void init() throws Exception {
22                 objectInspectorPayload = new ObjectInspectorPayload();
23                 message = new Message();
24
25           }
26         
27         
28         @Test 
29         public void updateValues() throws JsonParseException, JsonMappingException, IOException {
30                 
31                 objectInspectorPayload.setMessage(message);
32                 assertNotNull(objectInspectorPayload.getMessage());
33                 objectInspectorPayload.setTopic("sparky");
34                 assertNotNull(objectInspectorPayload.getTopic());
35                 objectInspectorPayload.setMessageType("subscribe");
36                 assertNotNull(objectInspectorPayload.getMessageType());
37                 objectInspectorPayload.setOrigin("portal-dispalyNotification");
38                 assertNotNull(objectInspectorPayload.getOrigin());
39                 objectInspectorPayload.setTarget("");
40                 assertNotNull(objectInspectorPayload.getTarget());      
41         }
42
43 }