[ONOS-2363]Implementation of Open and Error messages.
Change-Id: Id4aa762caf1847a6b5e56517cb159608fd54eefb
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/AdministrativeGroupTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/AdministrativeGroupTlvTest.java
new file mode 100644
index 0000000..297bd06
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/AdministrativeGroupTlvTest.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.AdministrativeGroupTlv;
+
+/**
+ * Test of the AdministrativeGroupTlv.
+ */
+public class AdministrativeGroupTlvTest {
+ private final AdministrativeGroupTlv tlv1 = AdministrativeGroupTlv.of(1);
+ private final AdministrativeGroupTlv sameAsTlv1 = AdministrativeGroupTlv.of(1);
+ private final AdministrativeGroupTlv tlv2 = AdministrativeGroupTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/AutonomousSystemTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/AutonomousSystemTlvTest.java
new file mode 100644
index 0000000..37fb558
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/AutonomousSystemTlvTest.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.AutonomousSystemTlv;
+
+/**
+ * Test of the AutonomousSystemTlv.
+ */
+public class AutonomousSystemTlvTest {
+ private final AutonomousSystemTlv tlv1 = AutonomousSystemTlv.of(1);
+ private final AutonomousSystemTlv sameAsTlv1 = AutonomousSystemTlv.of(1);
+ private final AutonomousSystemTlv tlv2 = AutonomousSystemTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/BGPLSidentifierTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/BGPLSidentifierTlvTest.java
new file mode 100644
index 0000000..e00646b
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/BGPLSidentifierTlvTest.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.BGPLSidentifierTlv;
+
+/**
+ * Test of the BGPLSidentifierTlv.
+ */
+public class BGPLSidentifierTlvTest {
+ private final BGPLSidentifierTlv tlv1 = BGPLSidentifierTlv.of(1);
+ private final BGPLSidentifierTlv sameAsTlv1 = BGPLSidentifierTlv.of(1);
+ private final BGPLSidentifierTlv tlv2 = BGPLSidentifierTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/GmplsCapabilityTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/GmplsCapabilityTlvTest.java
new file mode 100644
index 0000000..2b9a52b
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/GmplsCapabilityTlvTest.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.GmplsCapabilityTlv;
+
+/**
+ * Test of the GmplsCapabilityTlv.
+ */
+public class GmplsCapabilityTlvTest {
+ private final GmplsCapabilityTlv tlv1 = GmplsCapabilityTlv.of(1);
+ private final GmplsCapabilityTlv sameAsTlv1 = GmplsCapabilityTlv.of(1);
+ private final GmplsCapabilityTlv tlv2 = GmplsCapabilityTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IGPMetricTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IGPMetricTlvTest.java
new file mode 100644
index 0000000..3b4e0a2
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IGPMetricTlvTest.java
@@ -0,0 +1,40 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IGPMetricTlv;
+
+/**
+ * Test of the IGPMetricTlv.
+ */
+public class IGPMetricTlvTest {
+ private byte[] b1 = new byte[] {0x01, 0x02};
+ private byte[] b2 = new byte[] {0x01, 0x02};
+ private final IGPMetricTlv tlv1 = IGPMetricTlv.of(b1, (short) 2);
+ private final IGPMetricTlv sameAsTlv1 = IGPMetricTlv.of(b1, (short) 2);
+ private final IGPMetricTlv tlv2 = IGPMetricTlv.of(b2, (short) 2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4InterfaceAddressTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4InterfaceAddressTlvTest.java
new file mode 100644
index 0000000..5eb8cdf
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4InterfaceAddressTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv4InterfaceAddressTlv;
+
+/**
+ * Test of the IPv4InterfaceAddressTlv.
+ */
+public class IPv4InterfaceAddressTlvTest {
+
+ private final IPv4InterfaceAddressTlv tlv1 = IPv4InterfaceAddressTlv.of(2);
+ private final IPv4InterfaceAddressTlv sameAsTlv1 = IPv4InterfaceAddressTlv.of(2);
+ private final IPv4InterfaceAddressTlv tlv2 = IPv4InterfaceAddressTlv.of(3);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4NeighborAddressTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4NeighborAddressTlvTest.java
new file mode 100644
index 0000000..51d1d7b
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4NeighborAddressTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv4NeighborAddressTlv;
+
+/**
+ * Test of the IPv4NeighborAddressTlv.
+ */
+public class IPv4NeighborAddressTlvTest {
+
+ private final IPv4NeighborAddressTlv tlv1 = IPv4NeighborAddressTlv.of(2);
+ private final IPv4NeighborAddressTlv sameAsTlv1 = IPv4NeighborAddressTlv.of(2);
+ private final IPv4NeighborAddressTlv tlv2 = IPv4NeighborAddressTlv.of(3);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4TERouterIdOfLocalNodeTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4TERouterIdOfLocalNodeTlvTest.java
new file mode 100644
index 0000000..2a0e56c
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4TERouterIdOfLocalNodeTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv4TERouterIdOfLocalNodeTlv;
+
+/**
+ * Test of the IPv4TERouterIdOfLocalNodeTlv.
+ */
+public class IPv4TERouterIdOfLocalNodeTlvTest {
+
+ private final IPv4TERouterIdOfLocalNodeTlv tlv1 = IPv4TERouterIdOfLocalNodeTlv.of(2);
+ private final IPv4TERouterIdOfLocalNodeTlv sameAsTlv1 = IPv4TERouterIdOfLocalNodeTlv.of(2);
+ private final IPv4TERouterIdOfLocalNodeTlv tlv2 = IPv4TERouterIdOfLocalNodeTlv.of(3);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4TERouterIdOfRemoteNodeTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4TERouterIdOfRemoteNodeTlvTest.java
new file mode 100644
index 0000000..c7edf94
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv4TERouterIdOfRemoteNodeTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv4TERouterIdOfRemoteNodeTlv;
+
+/**
+ * Test of the IPv4TERouterIdOfRemoteNodeTlv.
+ */
+public class IPv4TERouterIdOfRemoteNodeTlvTest {
+
+ private final IPv4TERouterIdOfRemoteNodeTlv tlv1 = IPv4TERouterIdOfRemoteNodeTlv.of(2);
+ private final IPv4TERouterIdOfRemoteNodeTlv sameAsTlv1 = IPv4TERouterIdOfRemoteNodeTlv.of(2);
+ private final IPv4TERouterIdOfRemoteNodeTlv tlv2 = IPv4TERouterIdOfRemoteNodeTlv.of(3);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6InterfaceAddressTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6InterfaceAddressTlvTest.java
new file mode 100644
index 0000000..262fb77
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6InterfaceAddressTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv6InterfaceAddressTlv;
+
+/**
+ * Test of the IPv6InterfaceAddressTlv.
+ */
+public class IPv6InterfaceAddressTlvTest {
+
+ private byte[] b1 = new byte[] {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
+ private byte[] b2 = new byte[] {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 };
+
+ private final IPv6InterfaceAddressTlv tlv1 = IPv6InterfaceAddressTlv.of(b1);
+ private final IPv6InterfaceAddressTlv sameAsTlv1 = IPv6InterfaceAddressTlv.of(b1);
+ private final IPv6InterfaceAddressTlv tlv2 = IPv6InterfaceAddressTlv.of(b2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6NeighborAddressTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6NeighborAddressTlvTest.java
new file mode 100644
index 0000000..803b047
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6NeighborAddressTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv6NeighborAddressTlv;
+
+/**
+ * Test of the IPv6NeighborAddressTlv.
+ */
+public class IPv6NeighborAddressTlvTest {
+
+ private byte[] b1 = new byte[] {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
+ private byte[] b2 = new byte[] {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 };
+
+ private final IPv6NeighborAddressTlv tlv1 = IPv6NeighborAddressTlv.of(b1);
+ private final IPv6NeighborAddressTlv sameAsTlv1 = IPv6NeighborAddressTlv.of(b1);
+ private final IPv6NeighborAddressTlv tlv2 = IPv6NeighborAddressTlv.of(b2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6TERouterIdofLocalNodeTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6TERouterIdofLocalNodeTlvTest.java
new file mode 100644
index 0000000..59e6182
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6TERouterIdofLocalNodeTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv6TERouterIdofLocalNodeTlv;
+
+/**
+ * Test of the IPv6TERouterIdofLocalNodeTlv.
+ */
+public class IPv6TERouterIdofLocalNodeTlvTest {
+
+ private byte[] b1 = new byte[] {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
+ private byte[] b2 = new byte[] {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 };
+
+ private final IPv6TERouterIdofLocalNodeTlv tlv1 = IPv6TERouterIdofLocalNodeTlv.of(b1);
+ private final IPv6TERouterIdofLocalNodeTlv sameAsTlv1 = IPv6TERouterIdofLocalNodeTlv.of(b1);
+ private final IPv6TERouterIdofLocalNodeTlv tlv2 = IPv6TERouterIdofLocalNodeTlv.of(b2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6TERouterIdofRemoteNodeTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6TERouterIdofRemoteNodeTlvTest.java
new file mode 100644
index 0000000..41f8c20
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/IPv6TERouterIdofRemoteNodeTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv6TERouterIdofRemoteNodeTlv;
+
+/**
+ * Test of the IPv6TERouterIdofRemoteNodeTlv.
+ */
+public class IPv6TERouterIdofRemoteNodeTlvTest {
+
+ private byte[] b1 = new byte[] {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
+ private byte[] b2 = new byte[] {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 };
+
+ private final IPv6TERouterIdofRemoteNodeTlv tlv1 = IPv6TERouterIdofRemoteNodeTlv.of(b1);
+ private final IPv6TERouterIdofRemoteNodeTlv sameAsTlv1 = IPv6TERouterIdofRemoteNodeTlv.of(b1);
+ private final IPv6TERouterIdofRemoteNodeTlv tlv2 = IPv6TERouterIdofRemoteNodeTlv.of(b2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/ISISAreaIdentifierTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/ISISAreaIdentifierTlvTest.java
new file mode 100644
index 0000000..715339b
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/ISISAreaIdentifierTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.ISISAreaIdentifierTlv;
+
+/**
+ * Test of the ISISAreaIdentifierTlv.
+ */
+public class ISISAreaIdentifierTlvTest {
+
+ private byte[] b1 = new byte[] {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
+ private byte[] b2 = new byte[] {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 };
+
+ private final ISISAreaIdentifierTlv tlv1 = ISISAreaIdentifierTlv.of(b1, (short) 20);
+ private final ISISAreaIdentifierTlv sameAsTlv1 = ISISAreaIdentifierTlv.of(b1, (short) 20);
+ private final ISISAreaIdentifierTlv tlv2 = ISISAreaIdentifierTlv.of(b2, (short) 20);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkLocalRemoteIdentifiersTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkLocalRemoteIdentifiersTlvTest.java
new file mode 100644
index 0000000..e350cbb
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkLocalRemoteIdentifiersTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.LinkLocalRemoteIdentifiersTlv;
+
+/**
+ * Test of the LinkLocalRemoteIdentifiersTlv.
+ */
+public class LinkLocalRemoteIdentifiersTlvTest {
+
+ private final LinkLocalRemoteIdentifiersTlv tlv1 = LinkLocalRemoteIdentifiersTlv.of(10, 20);
+ private final LinkLocalRemoteIdentifiersTlv sameAsTlv1 = LinkLocalRemoteIdentifiersTlv.of(10, 20);
+ private final LinkLocalRemoteIdentifiersTlv tlv2 = LinkLocalRemoteIdentifiersTlv.of(20, 30);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkNameTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkNameTlvTest.java
new file mode 100644
index 0000000..25c7b64
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkNameTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.LinkNameTlv;
+
+/**
+ * Test of the LinkNameTlv.
+ */
+public class LinkNameTlvTest {
+ private final byte[] rawValue1 = new byte[] {0x01, 0x00};
+ private final byte[] rawValue2 = new byte[] {0x02, 0x00};
+
+ private final LinkNameTlv tlv1 = new LinkNameTlv(rawValue1, (short) rawValue1.length);
+ private final LinkNameTlv sameAsTlv1 = LinkNameTlv.of(tlv1.getValue(), tlv1.getLength());
+ private final LinkNameTlv tlv2 = new LinkNameTlv(rawValue2, (short) 0);
+ private final LinkNameTlv sameAsTlv2 = new LinkNameTlv(rawValue2, (short) rawValue2.length);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2, sameAsTlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkProtectionTypeTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkProtectionTypeTlvTest.java
new file mode 100644
index 0000000..29270b7
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/LinkProtectionTypeTlvTest.java
@@ -0,0 +1 @@
+/*
* Copyright 2014 Open Networking Laboratory
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.onosproject.pcepio;
import com.google.common.testing.EqualsTester;
import org.junit.Test;
import org.onosproject.pcepio.types.LinkProtectionTypeTlv;
/**
* Test of the LinkProtectionTypeTlv.
*/
public class LinkProtectionTypeTlvTest {
private final byte rawValue1 = 0x0A;
private final byte rawValue2 = 0x0A;
private final LinkProtectionTypeTlv tlv1 = new LinkProtectionTypeTlv(rawValue1);
private final LinkProtectionTypeTlv tlv2 = new LinkProtectionTypeTlv(rawValue2, (byte) 0);
@Test
public void basics() {
new EqualsTester()
.addEqualityGroup(tlv1, tlv2)
.testEquals();
}
}
\ No newline at end of file
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/MPLSProtocolMaskTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/MPLSProtocolMaskTlvTest.java
new file mode 100644
index 0000000..52f346a
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/MPLSProtocolMaskTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.MPLSProtocolMaskTlv;
+
+/**
+ * Test of the MPLSProtocolMaskTlv.
+ */
+public class MPLSProtocolMaskTlvTest {
+ private final byte rawValue1 = 0x0A;
+ private final byte rawValue2 = 0x0A;
+
+ private final MPLSProtocolMaskTlv tlv1 = new MPLSProtocolMaskTlv(rawValue1);
+ private final MPLSProtocolMaskTlv tlv2 = MPLSProtocolMaskTlv.of(rawValue2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/MaximumLinkBandwidthTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/MaximumLinkBandwidthTlvTest.java
new file mode 100644
index 0000000..831779a
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/MaximumLinkBandwidthTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.MaximumLinkBandwidthTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test of the MaximumLinkBandwidthTlv.
+ */
+public class MaximumLinkBandwidthTlvTest {
+ private final int rawValue1 = 0x0A;
+ private final int rawValue2 = 0x0A;
+
+ private final MaximumLinkBandwidthTlv tlv1 = new MaximumLinkBandwidthTlv(rawValue1);
+ private final MaximumLinkBandwidthTlv tlv2 = MaximumLinkBandwidthTlv.of(rawValue2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/MaximumReservableLinkBandwidthTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/MaximumReservableLinkBandwidthTlvTest.java
new file mode 100644
index 0000000..70e0b06
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/MaximumReservableLinkBandwidthTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.MaximumReservableLinkBandwidthTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test of the MaximumReservableLinkBandwidthTlv.
+ */
+public class MaximumReservableLinkBandwidthTlvTest {
+ private final int rawValue1 = 0x0A;
+ private final int rawValue2 = 0x0A;
+
+ private final MaximumReservableLinkBandwidthTlv tlv1 = new MaximumReservableLinkBandwidthTlv(rawValue1);
+ private final MaximumReservableLinkBandwidthTlv tlv2 = MaximumReservableLinkBandwidthTlv.of(rawValue2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/NodeFlagBitsTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/NodeFlagBitsTlvTest.java
new file mode 100644
index 0000000..7fb7109
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/NodeFlagBitsTlvTest.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.NodeFlagBitsTlv;
+
+/**
+ * Test of the NodeFlagBitsTlv.
+ */
+public class NodeFlagBitsTlvTest {
+ private final byte rawValue1 = 0x0A;
+
+ private final NodeFlagBitsTlv tlv1 = new NodeFlagBitsTlv(rawValue1);
+ private final NodeFlagBitsTlv tlv2 = NodeFlagBitsTlv.of(tlv1.getbyte());
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/NodeNameTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/NodeNameTlvTest.java
new file mode 100644
index 0000000..a824001
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/NodeNameTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.NodeNameTlv;
+
+/**
+ * Test of the NodeNameTlv.
+ */
+public class NodeNameTlvTest {
+ private final byte[] rawValue1 = new byte[] {0x01, 0x02};
+ private final byte[] rawValue2 = new byte[] {0x14, 0x15};
+
+ private final NodeNameTlv tlv1 = new NodeNameTlv(rawValue1, (short) rawValue1.length);
+ private final NodeNameTlv sameAsTlv1 = NodeNameTlv.of(tlv1.getValue(), tlv1.getLength());
+ private final NodeNameTlv tlv2 = new NodeNameTlv(rawValue2, (short) 0);
+ private final NodeNameTlv sameAsTlv2 = new NodeNameTlv(rawValue2, (short) rawValue2.length);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2, sameAsTlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/OSPFareaIDsubTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/OSPFareaIDsubTlvTest.java
new file mode 100644
index 0000000..dce63c7
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/OSPFareaIDsubTlvTest.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.OSPFareaIDsubTlv;
+
+/**
+ * Test of the OSPFareaIDsubTlv.
+ */
+public class OSPFareaIDsubTlvTest {
+ private final int rawValue1 = 0x0A;
+
+ private final OSPFareaIDsubTlv tlv1 = new OSPFareaIDsubTlv(rawValue1);
+ private final OSPFareaIDsubTlv tlv2 = OSPFareaIDsubTlv.of(tlv1.getInt());
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/OpaqueLinkAttributeTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/OpaqueLinkAttributeTlvTest.java
new file mode 100644
index 0000000..e7cf051
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/OpaqueLinkAttributeTlvTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.OpaqueLinkAttributeTlv;
+
+/**
+ * Test of the OpaqueLinkAttributeTlv.
+ */
+public class OpaqueLinkAttributeTlvTest {
+ private final byte[] rawValue1 = new byte[] {0x01, 0x02};
+ private final byte[] rawValue2 = new byte[] {0x14, 0x15};
+
+ private final OpaqueLinkAttributeTlv tlv1 = new OpaqueLinkAttributeTlv(rawValue1, (short) rawValue1.length);
+ private final OpaqueLinkAttributeTlv sameAsTlv1 = OpaqueLinkAttributeTlv.of(tlv1.getValue(), tlv1.getLength());
+ private final OpaqueLinkAttributeTlv tlv2 = new OpaqueLinkAttributeTlv(rawValue2, (short) 0);
+ private final OpaqueLinkAttributeTlv sameAsTlv2 = new OpaqueLinkAttributeTlv(rawValue2, (short) rawValue2.length);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, sameAsTlv1)
+ .addEqualityGroup(tlv2, sameAsTlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/PceccCapabilityTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/PceccCapabilityTlvTest.java
new file mode 100644
index 0000000..ca329cb
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/PceccCapabilityTlvTest.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2014 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import com.google.common.testing.EqualsTester;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.PceccCapabilityTlv;
+
+/**
+ * Test of the PceccCapabilityTlv.
+ */
+public class PceccCapabilityTlvTest {
+ private final int rawValue1 = 0x0A;
+ private final int rawValue2 = 0x0A;
+
+ private final PceccCapabilityTlv tlv1 = new PceccCapabilityTlv(rawValue1);
+ private final PceccCapabilityTlv tlv2 = PceccCapabilityTlv.of(rawValue2);
+
+ @Test
+ public void basics() {
+ new EqualsTester()
+ .addEqualityGroup(tlv1, tlv2)
+ .testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/RemoteTENodeDescriptorsTLVTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/RemoteTENodeDescriptorsTLVTest.java
new file mode 100644
index 0000000..43a9868
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/RemoteTENodeDescriptorsTLVTest.java
@@ -0,0 +1,53 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import java.util.LinkedList;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.AutonomousSystemTlv;
+import org.onosproject.pcepio.types.BGPLSidentifierTlv;
+import org.onosproject.pcepio.types.PcepValueType;
+import org.onosproject.pcepio.types.RemoteTENodeDescriptorsTLV;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for Remote TE Node Descriptors tlv.
+ */
+public class RemoteTENodeDescriptorsTLVTest {
+
+ AutonomousSystemTlv autonomousSystemTlv1 = new AutonomousSystemTlv(10);
+ BGPLSidentifierTlv bGPLSidentifierTlv1 = new BGPLSidentifierTlv(20);;
+ LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLVs1 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLVs2 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLVs3 = new LinkedList<PcepValueType>();
+
+ boolean b = llRemoteTENodeDescriptorSubTLVs1.add(autonomousSystemTlv1);
+
+ boolean c = llRemoteTENodeDescriptorSubTLVs2.add(autonomousSystemTlv1);
+ boolean d = llRemoteTENodeDescriptorSubTLVs3.add(bGPLSidentifierTlv1);
+
+ final RemoteTENodeDescriptorsTLV tlv1 = RemoteTENodeDescriptorsTLV.of(llRemoteTENodeDescriptorSubTLVs1);
+ final RemoteTENodeDescriptorsTLV tlv2 = RemoteTENodeDescriptorsTLV.of(llRemoteTENodeDescriptorSubTLVs2);
+ final RemoteTENodeDescriptorsTLV tlv3 = RemoteTENodeDescriptorsTLV.of(llRemoteTENodeDescriptorSubTLVs3);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/RouterIDSubTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/RouterIDSubTlvTest.java
new file mode 100644
index 0000000..ca07452
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/RouterIDSubTlvTest.java
@@ -0,0 +1,44 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.RouterIDSubTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for Router ID Sub tlv.
+ */
+public class RouterIDSubTlvTest {
+
+ private byte[] value1 = {1, 2 };
+ private Short length1 = new Short((short) 2);
+ private final RouterIDSubTlv tlv1 = RouterIDSubTlv.of(value1, length1);
+
+ private Short length2 = new Short((short) 2);
+ private final RouterIDSubTlv tlv2 = RouterIDSubTlv.of(value1, length2);
+
+ private byte[] value3 = {1, 2, 3 };
+ private Short length3 = new Short((short) 3);
+ private final RouterIDSubTlv tlv3 = RouterIDSubTlv.of(value3, length3);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/SharedRiskLinkGroupTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/SharedRiskLinkGroupTlvTest.java
new file mode 100644
index 0000000..0343bb0
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/SharedRiskLinkGroupTlvTest.java
@@ -0,0 +1,44 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.SharedRiskLinkGroupTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for Shared Risk Link Group tlv.
+ */
+public class SharedRiskLinkGroupTlvTest {
+
+ private int[] raw = {1 };
+ private Short hLength = new Short((short) 2);
+ private final SharedRiskLinkGroupTlv tlv1 = SharedRiskLinkGroupTlv.of(raw, hLength);
+
+ private Short hLength1 = new Short((short) 2);
+ private final SharedRiskLinkGroupTlv tlv2 = SharedRiskLinkGroupTlv.of(raw, hLength1);
+
+ private int[] raw2 = {2 };
+ private Short hLength2 = new Short((short) 3);
+ private SharedRiskLinkGroupTlv tlv3 = SharedRiskLinkGroupTlv.of(raw2, hLength2);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/StatefulLspDbVerTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/StatefulLspDbVerTlvTest.java
new file mode 100644
index 0000000..55a344e
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/StatefulLspDbVerTlvTest.java
@@ -0,0 +1,37 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.StatefulLspDbVerTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for Stateful Lsp Db Ver tlv.
+ */
+public class StatefulLspDbVerTlvTest {
+
+ private final StatefulLspDbVerTlv tlv1 = StatefulLspDbVerTlv.of(1);
+ private final StatefulLspDbVerTlv tlv2 = StatefulLspDbVerTlv.of(1);
+ private final StatefulLspDbVerTlv tlv3 = StatefulLspDbVerTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/StatefulPceCapabilityTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/StatefulPceCapabilityTlvTest.java
new file mode 100644
index 0000000..15e86d4
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/StatefulPceCapabilityTlvTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.StatefulPceCapabilityTlv;
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for Stateful Pce Capability tlv.
+ */
+public class StatefulPceCapabilityTlvTest {
+
+ private final StatefulPceCapabilityTlv tlv1 = StatefulPceCapabilityTlv.of(1);
+ private final StatefulPceCapabilityTlv tlv2 = StatefulPceCapabilityTlv.of(1);
+ private final StatefulPceCapabilityTlv tlv3 = StatefulPceCapabilityTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/TEDefaultMetricTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TEDefaultMetricTlvTest.java
new file mode 100644
index 0000000..913c99e
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TEDefaultMetricTlvTest.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.TEDefaultMetricTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for TE Default Metric tlv.
+ */
+public class TEDefaultMetricTlvTest {
+
+ private final TEDefaultMetricTlv tlv1 = TEDefaultMetricTlv.of(1);
+ private final TEDefaultMetricTlv tlv2 = TEDefaultMetricTlv.of(1);
+ private final TEDefaultMetricTlv tlv3 = TEDefaultMetricTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/TELinkAttributesTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TELinkAttributesTlvTest.java
new file mode 100644
index 0000000..55d2851
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TELinkAttributesTlvTest.java
@@ -0,0 +1,53 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import java.util.LinkedList;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.AdministrativeGroupTlv;
+import org.onosproject.pcepio.types.MaximumReservableLinkBandwidthTlv;
+import org.onosproject.pcepio.types.PcepValueType;
+import org.onosproject.pcepio.types.TELinkAttributesTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for TE Link Attribute Tlv.
+ */
+public class TELinkAttributesTlvTest {
+
+ AdministrativeGroupTlv administrativeGroupTlv1 = new AdministrativeGroupTlv(10);
+ MaximumReservableLinkBandwidthTlv maximumReservableLinkBandwidthTlv1 = new MaximumReservableLinkBandwidthTlv(20);;
+ LinkedList<PcepValueType> llLinkAttributesSubTLVs = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llLinkAttributesSubTLVs2 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llLinkAttributesSubTLVs3 = new LinkedList<PcepValueType>();
+
+ boolean b = llLinkAttributesSubTLVs.add(administrativeGroupTlv1);
+
+ boolean c = llLinkAttributesSubTLVs2.add(administrativeGroupTlv1);
+ boolean d = llLinkAttributesSubTLVs3.add(maximumReservableLinkBandwidthTlv1);
+
+ final TELinkAttributesTlv tlv1 = TELinkAttributesTlv.of(llLinkAttributesSubTLVs);
+ final TELinkAttributesTlv tlv2 = TELinkAttributesTlv.of(llLinkAttributesSubTLVs2);
+ final TELinkAttributesTlv tlv3 = TELinkAttributesTlv.of(llLinkAttributesSubTLVs3);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/TELinkDescriptorsTLVTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TELinkDescriptorsTLVTest.java
new file mode 100644
index 0000000..42d0c42
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TELinkDescriptorsTLVTest.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import java.util.LinkedList;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv4InterfaceAddressTlv;
+import org.onosproject.pcepio.types.LinkLocalRemoteIdentifiersTlv;
+import org.onosproject.pcepio.types.PcepValueType;
+import org.onosproject.pcepio.types.TELinkDescriptorsTLV;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for TE link descriptors Tlv.
+ */
+public class TELinkDescriptorsTLVTest {
+ LinkLocalRemoteIdentifiersTlv linkLocalRemoteIdentifiersTlv1 = new LinkLocalRemoteIdentifiersTlv(10, 10);
+ IPv4InterfaceAddressTlv iPv4InterfaceAddressTlv1 = new IPv4InterfaceAddressTlv((int) 0x01010101);
+ LinkedList<PcepValueType> llLinkDescriptorsSubTLVs1 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llLinkDescriptorsSubTLVs2 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llLinkDescriptorsSubTLVs3 = new LinkedList<PcepValueType>();
+
+ boolean b = llLinkDescriptorsSubTLVs1.add(linkLocalRemoteIdentifiersTlv1);
+ boolean c = llLinkDescriptorsSubTLVs2.add(linkLocalRemoteIdentifiersTlv1);
+ boolean d = llLinkDescriptorsSubTLVs3.add(iPv4InterfaceAddressTlv1);
+
+ final TELinkDescriptorsTLV tlv1 = TELinkDescriptorsTLV.of(llLinkDescriptorsSubTLVs1);
+ final TELinkDescriptorsTLV tlv2 = TELinkDescriptorsTLV.of(llLinkDescriptorsSubTLVs2);
+ final TELinkDescriptorsTLV tlv3 = TELinkDescriptorsTLV.of(llLinkDescriptorsSubTLVs3);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/TENodeAttributesTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TENodeAttributesTlvTest.java
new file mode 100644
index 0000000..a4e7fee
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TENodeAttributesTlvTest.java
@@ -0,0 +1,53 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import java.util.LinkedList;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.IPv4TERouterIdOfLocalNodeTlv;
+import org.onosproject.pcepio.types.NodeFlagBitsTlv;
+import org.onosproject.pcepio.types.PcepValueType;
+import org.onosproject.pcepio.types.TENodeAttributesTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for TE Node Attribute tlv.
+ */
+public class TENodeAttributesTlvTest {
+
+ NodeFlagBitsTlv nodeFlagBitsTlv1 = new NodeFlagBitsTlv((byte) 10);
+ IPv4TERouterIdOfLocalNodeTlv iPv4TERouterIdOfLocalNodeTlv1 = new IPv4TERouterIdOfLocalNodeTlv((int) 0x01010101);;
+ LinkedList<PcepValueType> llNodeAttributesSubTLVs1 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llNodeAttributesSubTLVs2 = new LinkedList<PcepValueType>();
+ LinkedList<PcepValueType> llNodeAttributesSubTLVs3 = new LinkedList<PcepValueType>();
+
+ boolean b = llNodeAttributesSubTLVs1.add(nodeFlagBitsTlv1);
+
+ boolean c = llNodeAttributesSubTLVs2.add(nodeFlagBitsTlv1);
+ boolean d = llNodeAttributesSubTLVs3.add(iPv4TERouterIdOfLocalNodeTlv1);
+
+ final TENodeAttributesTlv tlv1 = TENodeAttributesTlv.of(llNodeAttributesSubTLVs1);
+ final TENodeAttributesTlv tlv2 = TENodeAttributesTlv.of(llNodeAttributesSubTLVs2);
+ final TENodeAttributesTlv tlv3 = TENodeAttributesTlv.of(llNodeAttributesSubTLVs3);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/TedCapabilityTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TedCapabilityTlvTest.java
new file mode 100644
index 0000000..d94bbde
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/TedCapabilityTlvTest.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.TedCapabilityTlv;
+
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Test case for TED Capability tlv.
+ */
+public class TedCapabilityTlvTest {
+
+ private final TedCapabilityTlv tlv1 = TedCapabilityTlv.of(1);
+ private final TedCapabilityTlv tlv2 = TedCapabilityTlv.of(1);
+ private final TedCapabilityTlv tlv3 = TedCapabilityTlv.of(2);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+}
diff --git a/pcep/pcepio/src/test/java/org/onosproject/pcepio/UnreservedBandwidthTlvTest.java b/pcep/pcepio/src/test/java/org/onosproject/pcepio/UnreservedBandwidthTlvTest.java
new file mode 100644
index 0000000..1fb197c
--- /dev/null
+++ b/pcep/pcepio/src/test/java/org/onosproject/pcepio/UnreservedBandwidthTlvTest.java
@@ -0,0 +1,37 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.pcepio;
+
+import org.junit.Test;
+import org.onosproject.pcepio.types.UnreservedBandwidthTlv;
+import com.google.common.testing.EqualsTester;
+
+/**
+ * Unit Test case for Unreserved Bandwidth Tlv.
+ */
+public class UnreservedBandwidthTlvTest {
+
+ // Objects of unreserved bandwidth tlv
+ private final UnreservedBandwidthTlv tlv1 = UnreservedBandwidthTlv.of(100);
+ private final UnreservedBandwidthTlv tlv2 = UnreservedBandwidthTlv.of(100);
+ private final UnreservedBandwidthTlv tlv3 = UnreservedBandwidthTlv.of(200);
+
+ @Test
+ public void basics() {
+ new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
+ }
+
+}