Merge "Option to receive only leaf nodes in websocket notifs"
[netconf.git] / netconf / sal-netconf-connector / src / test / java / org / opendaylight / netconf / sal / connect / netconf / sal / NetconfDeviceSalProviderTest.java
index 7fd6b9695783907299fea373b148012116d7af27..b49b3fd3fbe93091133a8db3ced5b983479059ba 100644 (file)
@@ -94,4 +94,12 @@ public class NetconfDeviceSalProviderTest {
         verify(chain).close();
     }
 
+    @Test
+    public void closeWithoutNPE() throws Exception {
+        provider.onSessionInitiated(session);
+        provider.onSessionInitiated(context);
+        provider.close();
+        provider.close();
+        verify(chain, times(2)).close();
+    }
 }
\ No newline at end of file