You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@depot.apache.org by aj...@apache.org on 2004/05/02 18:18:21 UTC
svn commit: rev 10492 - incubator/depot/trunk/update/src/test/org/apache/depot/update/util/text
Author: ajack
Date: Sun May 2 11:18:20 2004
New Revision: 10492
Modified:
incubator/depot/trunk/update/src/test/org/apache/depot/update/util/text/MessageTests.java
Log:
Fixed obsolete test to really be one.
Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/util/text/MessageTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/util/text/MessageTests.java (original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/util/text/MessageTests.java Sun May 2 11:18:20 2004
@@ -32,22 +32,23 @@
}
public void testMessages() throws Exception {
- List messageCodes = MessageConstants.getCodes();
+ List inJavaCodes = MessageConstants.getCodes();
- for (Iterator i = messageCodes.iterator(); i.hasNext();) {
+ // Find any in Java but not in resource bundle
+ for (Iterator i = inJavaCodes.iterator(); i.hasNext();) {
String code = (String) i.next();
assertNotNull(code, Messages.loadMessageFormat(code));
}
}
public void testForObsolete() throws Exception {
- List messageCodes1 = MessageConstants.getCodes();
- List messageCodes2 = Messages.getCodes();
+ List inJavaCodes = MessageConstants.getCodes();
+ List inResourceCodes = Messages.getCodes();
- for (Iterator i = messageCodes1.iterator(); i.hasNext();) {
+ // Find any in resource bundle but not in Java
+ for (Iterator i = inResourceCodes.iterator(); i.hasNext();) {
String code = (String) i.next();
-
- assertTrue("Obsolete : " + code, messageCodes2.contains(code));
+ assertTrue("Obsolete : " + code, inJavaCodes.contains(code));
}
}