Avoid NPE warning by using assertNotNull
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/collections/trunk@1023835 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
d0f6869a56
commit
2e2bca346b
|
@ -482,11 +482,11 @@ public abstract class AbstractTestMap<K, V> extends AbstractTestObject {
|
|||
Object[] values = getSampleValues();
|
||||
Object[] newValues = getNewSampleValues();
|
||||
|
||||
assertTrue("failure in test: Must have keys returned from " +
|
||||
"getSampleKeys.", keys != null);
|
||||
assertNotNull("failure in test: Must have keys returned from " +
|
||||
"getSampleKeys.", keys);
|
||||
|
||||
assertTrue("failure in test: Must have values returned from " +
|
||||
"getSampleValues.", values != null);
|
||||
assertNotNull("failure in test: Must have values returned from " +
|
||||
"getSampleValues.", values);
|
||||
|
||||
// verify keys and values have equivalent lengths (in case getSampleX are
|
||||
// overridden)
|
||||
|
|
Loading…
Reference in New Issue