diff options
author | Matthieu Geerebaert <matthieu.geerebaert@orange.com> | 2018-04-23 14:14:55 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2018-04-23 14:14:55 +0000 |
commit | 0d31f4100b577a231649e48e02ab7d96ce8a0699 (patch) | |
tree | 980f7f04022b31a5e9c8234714785586a5afff85 | |
parent | 71e7ffef63a2e998541a4ba68f832ec5c7dfcb5f (diff) | |
parent | e0a1b2fb28cb5ef24d9d670832136bb57820c3e1 (diff) |
Merge "fix NPE serviceOrder"
-rw-r--r-- | src/test/java/org/onap/nbi/apis/ApiTest.java | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/test/java/org/onap/nbi/apis/ApiTest.java b/src/test/java/org/onap/nbi/apis/ApiTest.java index 563760e..937f417 100644 --- a/src/test/java/org/onap/nbi/apis/ApiTest.java +++ b/src/test/java/org/onap/nbi/apis/ApiTest.java @@ -289,6 +289,24 @@ public class ApiTest { } + + @Test + public void testCheckServiceOrderWithoutRelatedParty() throws Exception { + + ServiceOrder testServiceOrder = ServiceOrderAssertions.createTestServiceOrder(ActionType.ADD); + testServiceOrder.setRelatedParty(null); + testServiceOrder.setState(StateType.ACKNOWLEDGED); + testServiceOrder.setId("test"); + serviceOrderRepository.save(testServiceOrder); + + serviceOrderResource.scheduleCheckServiceOrders(); + + ServiceOrder serviceOrderChecked = serviceOrderRepository.findOne("test"); + assertThat(serviceOrderChecked.getState()).isEqualTo(StateType.ACKNOWLEDGED); + + + } + @Test public void testCheckServiceOrderWithUnKnonwCustomer() throws Exception { |