// expected
}
}
public void testTransformedBag() {
Bag bag = BagUtils.transformedBag(new HashBag(), nopTransformer);
assertTrue("Returned object should be an TransformedBag.",
bag instanceof TransformedBag);
try {
bag = BagUtils.transformedBag(null, nopTransformer);
fail("Expecting IllegalArgumentException for null bag.");
} catch (IllegalArgumentException ex) {
// expected
}
try {
bag = BagUtils.transformedBag(new HashBag(), null);
fail("Expecting IllegalArgumentException for null transformer.");
} catch (IllegalArgumentException ex) {
// expected
}
}