Method names and signatures changed to make more generally useful and clear

git-svn-id: https://svn.apache.org/repos/asf/jakarta/commons/proper/collections/trunk@131001 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Stephen Colebourne 2003-04-09 23:38:26 +00:00
parent aa46c52439
commit 66a915ccb5
2 changed files with 26 additions and 26 deletions

View File

@ -1,7 +1,7 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/TestListUtils.java,v 1.7 2003/04/04 22:22:28 scolebourne Exp $
* $Revision: 1.7 $
* $Date: 2003/04/04 22:22:28 $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/TestListUtils.java,v 1.8 2003/04/09 23:38:26 scolebourne Exp $
* $Revision: 1.8 $
* $Date: 2003/04/09 23:38:26 $
*
* ====================================================================
*
@ -167,12 +167,12 @@ public class TestListUtils extends BulkTest {
List b = new ArrayList( data );
assertEquals(true, a.equals(b));
assertEquals(true, ListUtils.equals(a, b));
assertEquals(true, ListUtils.isEqualList(a, b));
a.clear();
assertEquals(false, ListUtils.equals(a, b));
assertEquals(false, ListUtils.equals(a, null));
assertEquals(false, ListUtils.equals(null, b));
assertEquals(true, ListUtils.equals(null, null));
assertEquals(false, ListUtils.isEqualList(a, b));
assertEquals(false, ListUtils.isEqualList(a, null));
assertEquals(false, ListUtils.isEqualList(null, b));
assertEquals(true, ListUtils.isEqualList(null, null));
}
public void testHashCode() {
@ -182,12 +182,12 @@ public class TestListUtils extends BulkTest {
List b = new ArrayList( data );
assertEquals(true, a.hashCode() == b.hashCode());
assertEquals(true, a.hashCode() == ListUtils.hashCode(a));
assertEquals(true, b.hashCode() == ListUtils.hashCode(b));
assertEquals(true, ListUtils.hashCode(a) == ListUtils.hashCode(b));
assertEquals(true, a.hashCode() == ListUtils.hashCodeForList(a));
assertEquals(true, b.hashCode() == ListUtils.hashCodeForList(b));
assertEquals(true, ListUtils.hashCodeForList(a) == ListUtils.hashCodeForList(b));
a.clear();
assertEquals(false, ListUtils.hashCode(a) == ListUtils.hashCode(b));
assertEquals(0, ListUtils.hashCode(null));
assertEquals(false, ListUtils.hashCodeForList(a) == ListUtils.hashCodeForList(b));
assertEquals(0, ListUtils.hashCodeForList(null));
}
}

View File

@ -1,7 +1,7 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/TestSetUtils.java,v 1.5 2003/04/04 22:22:28 scolebourne Exp $
* $Revision: 1.5 $
* $Date: 2003/04/04 22:22:28 $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/TestSetUtils.java,v 1.6 2003/04/09 23:38:26 scolebourne Exp $
* $Revision: 1.6 $
* $Date: 2003/04/09 23:38:26 $
*
* ====================================================================
*
@ -148,12 +148,12 @@ public class TestSetUtils extends BulkTest {
Set b = new HashSet( data );
assertEquals(true, a.equals(b));
assertEquals(true, SetUtils.equals(a, b));
assertEquals(true, SetUtils.isEqualSet(a, b));
a.clear();
assertEquals(false, SetUtils.equals(a, b));
assertEquals(false, SetUtils.equals(a, null));
assertEquals(false, SetUtils.equals(null, b));
assertEquals(true, SetUtils.equals(null, null));
assertEquals(false, SetUtils.isEqualSet(a, b));
assertEquals(false, SetUtils.isEqualSet(a, null));
assertEquals(false, SetUtils.isEqualSet(null, b));
assertEquals(true, SetUtils.isEqualSet(null, null));
}
public void testHashCode() {
@ -163,12 +163,12 @@ public class TestSetUtils extends BulkTest {
Set b = new HashSet( data );
assertEquals(true, a.hashCode() == b.hashCode());
assertEquals(true, a.hashCode() == SetUtils.hashCode(a));
assertEquals(true, b.hashCode() == SetUtils.hashCode(b));
assertEquals(true, SetUtils.hashCode(a) == SetUtils.hashCode(b));
assertEquals(true, a.hashCode() == SetUtils.hashCodeForSet(a));
assertEquals(true, b.hashCode() == SetUtils.hashCodeForSet(b));
assertEquals(true, SetUtils.hashCodeForSet(a) == SetUtils.hashCodeForSet(b));
a.clear();
assertEquals(false, SetUtils.hashCode(a) == SetUtils.hashCode(b));
assertEquals(0, SetUtils.hashCode(null));
assertEquals(false, SetUtils.hashCodeForSet(a) == SetUtils.hashCodeForSet(b));
assertEquals(0, SetUtils.hashCodeForSet(null));
}
}