2 * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.yangtools.yang.data.api.schema;
10 import static org.junit.Assert.assertEquals;
11 import static org.mockito.Mockito.mock;
14 import org.junit.Test;
16 public class DuplicityTest {
18 public void testDuplicate() {
19 final LeafNode<?> leafNode = mock(LeafNode.class);
20 final ContainerNode containerNode = mock(ContainerNode.class);
21 final Map<NormalizedNode, DuplicateEntry> normalizedNodeDuplicateEntryMapNode = NormalizedNodes
22 .findDuplicates(leafNode);
23 final Map<NormalizedNode, DuplicateEntry> normalizedNodeDuplicateEntryMapContainer = NormalizedNodes
24 .findDuplicates(containerNode);
25 assertEquals(0, normalizedNodeDuplicateEntryMapNode.size());
26 assertEquals(0, normalizedNodeDuplicateEntryMapContainer.size());