Replaced all tabs with spaces in java and pom.xml
[so.git] / bpmn / MSOCommonBPMN / src / test / java / org / onap / so / client / cds / beans / ConfigDeployRequestPnfTest.java
1 package org.onap.so.client.cds.beans;
2
3 import static org.junit.Assert.assertEquals;
4 import static org.junit.Assert.assertNotNull;
5 import org.junit.Test;
6
7 public class ConfigDeployRequestPnfTest {
8     ConfigDeployRequestPnf configDeployRequestPnf = new ConfigDeployRequestPnf();
9     private String resolutionKey;
10     ConfigDeployPropertiesForPnf configDeployPropertiesForPnf = new ConfigDeployPropertiesForPnf();
11
12     @Test
13     public final void testConfigDeployRequestVnf() {
14         configDeployRequestPnf.setResolutionKey("resolution-key");
15         configDeployRequestPnf.setConfigDeployPropertiesForPnf(configDeployPropertiesForPnf);
16         assertNotNull(configDeployRequestPnf.getResolutionKey());
17         assertNotNull(configDeployRequestPnf.getConfigDeployPropertiesForPnf());
18         assertEquals("resolution-key", configDeployRequestPnf.getResolutionKey());
19         assertEquals(configDeployPropertiesForPnf, configDeployRequestPnf.getConfigDeployPropertiesForPnf());
20     }
21
22     @Test
23     public void testtoString() {
24         configDeployPropertiesForPnf.setServiceInstanceId("service-instance-id");
25         configDeployPropertiesForPnf.setServiceModelUuid("service-model-uuid");
26         configDeployPropertiesForPnf.setPnfCustomizationUuid("pnf-customization-uuid");
27         configDeployPropertiesForPnf.setPnfId("pnf-id");
28         configDeployPropertiesForPnf.setPnfName("pnf-name");
29         configDeployRequestPnf.setConfigDeployPropertiesForPnf(configDeployPropertiesForPnf);
30         final StringBuilder sb = new StringBuilder("{\"config-deploy-request\":{");
31         sb.append("\"resolution-key\":").append("\"").append(resolutionKey).append("\"");
32         sb.append(", \"config-deploy-properties\":").append(configDeployPropertiesForPnf.toString());
33         sb.append('}');
34         sb.append('}');
35         String Expexted = sb.toString();
36
37         assertEquals(Expexted, configDeployRequestPnf.toString());
38     }
39
40 }