@@ -0,0 +1,1991 @@
+/*%0A * Copyright 2015 Open Networking Laboratory%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A *     http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0Apackage org.onosproject.vtnrsc.subnet;%0A%0Aimport static org.hamcrest.MatcherAssert.assertThat;%0Aimport static org.hamcrest.Matchers.is;%0Aimport static org.hamcrest.Matchers.notNullValue;%0Aimport static org.onlab.junit.ImmutableClassChecker.assertThatClassIsImmutable;%0A%0Aimport org.junit.Test;%0Aimport org.onosproject.vtnrsc.SubnetId;%0A%0Aimport com.google.common.testing.EqualsTester;%0A%0A/**%0A * Unit tests for SubnetId class.%0A */%0Apublic class SubnetIdTest %7B%0A%0A    final SubnetId subnetId1 = SubnetId.subnetId(%221%22);%0A    final SubnetId sameAsSubnetId1 = SubnetId.subnetId(%221%22);%0A    final SubnetId subnetId2 = SubnetId.subnetId(%222%22);%0A%0A    /**%0A     * Checks that the SubnetId class is immutable.%0A     */%0A    @Test%0A    public void testImmutability() %7B%0A        assertThatClassIsImmutable(SubnetId.class);%0A    %7D%0A%0A    /**%0A     * Checks the operation of equals() methods.%0A     */%0A    @Test%0A    public void testEquals() %7B%0A        new EqualsTester().addEqualityGroup(subnetId1, sameAsSubnetId1).addEqualityGroup(subnetId2)%0A                .testEquals();%0A    %7D%0A%0A    /**%0A     * Checks the construction of a SubnetId object.%0A     */%0A    @Test%0A    public void testConstruction() %7B%0A        final String subnetIdValue = %22s%22;%0A        final SubnetId subnetId = SubnetId.subnetId(subnetIdValue);%0A        assertThat(subnetId, is(notNullValue()));%0A        assertThat(subnetId.subnetId(), is(subnetIdValue));%0A    %7D%0A%7D%0A

Add the junit test code of SubnetId