X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;ds=sidebyside;f=opendaylight%2Fadsal%2Fnorthbound%2Fsubnets%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsubnets%2Fnorthbound%2FSubnetsNorthboundTest.java;fp=opendaylight%2Fadsal%2Fnorthbound%2Fsubnets%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsubnets%2Fnorthbound%2FSubnetsNorthboundTest.java;h=833b5d4ce7710a57c930ed595995a02a61eaff80;hb=42c32160bfd41de57189bb246fec5ffb48ed8e9e;hp=0000000000000000000000000000000000000000;hpb=edf5bfcee83c750853253ccfd991ba7000f5f65b;p=controller.git diff --git a/opendaylight/adsal/northbound/subnets/src/test/java/org/opendaylight/controller/subnets/northbound/SubnetsNorthboundTest.java b/opendaylight/adsal/northbound/subnets/src/test/java/org/opendaylight/controller/subnets/northbound/SubnetsNorthboundTest.java new file mode 100644 index 0000000000..833b5d4ce7 --- /dev/null +++ b/opendaylight/adsal/northbound/subnets/src/test/java/org/opendaylight/controller/subnets/northbound/SubnetsNorthboundTest.java @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2014 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ +package org.opendaylight.controller.subnets.northbound; + +import java.util.ArrayList; + +import org.junit.Assert; +import org.junit.Test; +import org.opendaylight.controller.switchmanager.SubnetConfig; + +public class SubnetsNorthboundTest { + + @Test + public void testSubnetConfigs() { + SubnetConfigs sc1 = new SubnetConfigs(null); + Assert.assertNull(sc1.getSubnetConfig()); + + ArrayList list = new ArrayList(); + SubnetConfig s1 = new SubnetConfig(); + list.add(s1); + sc1.setSubnetConfig(list); + Assert.assertTrue(sc1.getSubnetConfig().equals(list)); + + sc1.setSubnetConfig(null); + Assert.assertNull(sc1.getSubnetConfig()); + } + +}