blob: 5f470c4311e19ae23ffffbe1340a4410610d3dc7 [file] [log] [blame]
Sho SHIMIZUaf1dffc2015-09-04 15:56:07 -07001/*
Brian O'Connor5ab426f2016-04-09 01:19:45 -07002 * Copyright 2015-present Open Networking Laboratory
Sho SHIMIZUaf1dffc2015-09-04 15:56:07 -07003 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
Sho SHIMIZU3559c312015-11-04 14:59:31 -080016package org.onosproject.pcepio.types;
Sho SHIMIZUaf1dffc2015-09-04 15:56:07 -070017
18import com.google.common.testing.EqualsTester;
Sho SHIMIZU3559c312015-11-04 14:59:31 -080019import org.junit.Test;
Sho SHIMIZUaf1dffc2015-09-04 15:56:07 -070020
21public class PcepNaiUnnumberedAdjacencyIpv4Test {
22
23 private final int localNodeId1 = 1;
24 private final int localInterfaceId1 = 1;
25 private final int remoteNodeId1 = 1;
26 private final int remoteInterfaceId1 = 1;
27 private final PcepNaiUnnumberedAdjacencyIpv4 tlv1 = PcepNaiUnnumberedAdjacencyIpv4.of(localNodeId1,
28 localInterfaceId1, remoteNodeId1, remoteInterfaceId1);
29
30 private final int localNodeId2 = 1;
31 private final int localInterfaceId2 = 1;
32 private final int remoteNodeId2 = 1;
33 private final int remoteInterfaceId2 = 1;
34 private final PcepNaiUnnumberedAdjacencyIpv4 tlv2 = PcepNaiUnnumberedAdjacencyIpv4.of(localNodeId2,
35 localInterfaceId2, remoteNodeId2, remoteInterfaceId2);
36
37 private final int localNodeId3 = 2;
38 private final int localInterfaceId3 = 2;
39 private final int remoteNodeId3 = 2;
40 private final int remoteInterfaceId3 = 2;
41
42 private final PcepNaiUnnumberedAdjacencyIpv4 tlv3 = PcepNaiUnnumberedAdjacencyIpv4.of(localNodeId3,
43 localInterfaceId3, remoteNodeId3, remoteInterfaceId3);
44
45 @Test
46 public void basics() {
47 new EqualsTester().addEqualityGroup(tlv1, tlv2).addEqualityGroup(tlv3).testEquals();
48 }
49}