Update of /var/cvs/tests/bridge/org/mmbase/bridge
In directory james.mmbase.org:/tmp/cvs-serv28040

Modified Files:
        NodeTest.java 
Log Message:
added a test-case about useage of non-existing fields


See also: http://cvs.mmbase.org/viewcvs/tests/bridge/org/mmbase/bridge


Index: NodeTest.java
===================================================================
RCS file: /var/cvs/tests/bridge/org/mmbase/bridge/NodeTest.java,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -b -r1.22 -r1.23
--- NodeTest.java       17 Jul 2008 16:02:04 -0000      1.22
+++ NodeTest.java       22 Sep 2008 16:40:49 -0000      1.23
@@ -363,5 +363,14 @@
         }
     }
 
+    public void testNonExistingField() {
+        try {
+            node.getStringValue("nonexistingfield");
+            fail("Getting non existing field should throw a (clear) 
exception");
+        } catch (RuntimeException e) {
+            
assertTrue(java.util.regex.Pattern.compile(".*field.*nonexistingfield.*").matcher(e.getMessage()).matches());
+        }
+    }
+
 
 }
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to