Reorder tests, remove TODO as it should be fine imho.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/collections/trunk@1475953 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
766d9add03
commit
0c05822544
|
@ -37,17 +37,6 @@ public class TreeBagTest<T> extends AbstractSortedBagTest<T> {
|
||||||
return new TreeBag<T>();
|
return new TreeBag<T>();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Generics (for example... is this even needed?)
|
|
||||||
public void testCollections265() {
|
|
||||||
final Bag<Object> bag = new TreeBag<Object>();
|
|
||||||
try {
|
|
||||||
bag.add(new Object());
|
|
||||||
fail("IllegalArgumentException expected");
|
|
||||||
} catch(final IllegalArgumentException iae) {
|
|
||||||
// expected;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
public SortedBag<T> setupBag() {
|
public SortedBag<T> setupBag() {
|
||||||
final SortedBag<T> bag = makeObject();
|
final SortedBag<T> bag = makeObject();
|
||||||
|
@ -58,6 +47,16 @@ public class TreeBagTest<T> extends AbstractSortedBagTest<T> {
|
||||||
return bag;
|
return bag;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void testCollections265() {
|
||||||
|
final Bag<Object> bag = new TreeBag<Object>();
|
||||||
|
try {
|
||||||
|
bag.add(new Object());
|
||||||
|
fail("IllegalArgumentException expected");
|
||||||
|
} catch(final IllegalArgumentException iae) {
|
||||||
|
// expected;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public void testOrdering() {
|
public void testOrdering() {
|
||||||
final Bag<T> bag = setupBag();
|
final Bag<T> bag = setupBag();
|
||||||
assertEquals("Should get elements in correct order", "A", bag.toArray()[0]);
|
assertEquals("Should get elements in correct order", "A", bag.toArray()[0]);
|
||||||
|
|
Loading…
Reference in New Issue