Update of /cvsroot/xdoclet/xdoclet2/src/test/java/xdoclet/util/predicates
In directory sc8-pr-cvs1:/tmp/cvs-serv27037/src/test/java/xdoclet/util/predicates

Added Files:
        ReflectionPredicateTest.java 
Log Message:
Hardened and slightly refactored ReflectionPredicate.

--- NEW FILE: ReflectionPredicateTest.java ---
package xdoclet.util.predicates;

import junit.framework.TestCase;

/**
 * Test for [EMAIL PROTECTED] ReflectionPredicate}.
 *
 * @version $Revision: 1.1 $
 * @author <a href="mailto:[EMAIL PROTECTED]">Mathias Bogaert</a>
 */
public class ReflectionPredicateTest extends TestCase {
    public void testReflectionPredicate() {
        // fucked up tests
        try {
            new ReflectionPredicate(null);
            fail("new ReflectionPredicate(null) does not throw 
IllegalArgumentException");
        }
        catch (IllegalArgumentException e) {
            // good
        }

        try {
            new ReflectionPredicate("");
            new ReflectionPredicate("    ");
            fail("new ReflectionPredicate(\"\") does not throw 
IllegalArgumentException");
        }
        catch (IllegalArgumentException e) {
            // good
        }
    }
}



-------------------------------------------------------
This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger 
for complex code. Debugging C/C++ programs can leave you feeling lost and 
disoriented. TotalView can help you find your way. Available on major UNIX 
and Linux platforms. Try it free. www.etnus.com
_______________________________________________
xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel

Reply via email to