KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > test > collections > UnorderedUncountedCollectionComparerTest


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
3  */

4 package com.tc.test.collections;
5
6 /**
7  * Unit test for {@link UnorderedUncountedCollectionComparer}.
8  */

9 public class UnorderedUncountedCollectionComparerTest extends UnorderedCollectionComparerTest {
10
11   public void setUp() throws Exception JavaDoc {
12     super.setUp();
13     this.comparer = new UnorderedUncountedCollectionComparer(this.equalityComparator, this.describer);
14   }
15
16   public void testChecksCounts() throws Exception JavaDoc {
17     MyObj one = new MyObj("a");
18     MyObj two = new MyObj("b");
19
20     checkMismatches(NO_MISMATCHES, this.comparer.getMismatches(new Object JavaDoc[] { one, one, two, new MyObj("c") },
21                                                                new Object JavaDoc[] { two, two, one, new MyObj("c") }));
22   }
23
24 }
Popular Tags