Author: ruschein
Date: 2010-08-31 16:35:56 -0700 (Tue, 31 Aug 2010)
New Revision: 21646
Modified:
core3/work-api/trunk/src/test/java/org/cytoscape/work/TaskIteratorTest.java
Log:
Added one more method test.
Modified:
core3/work-api/trunk/src/test/java/org/cytoscape/work/TaskIteratorTest.java
===================================================================
--- core3/work-api/trunk/src/test/java/org/cytoscape/work/TaskIteratorTest.java
2010-08-31 23:35:54 UTC (rev 21645)
+++ core3/work-api/trunk/src/test/java/org/cytoscape/work/TaskIteratorTest.java
2010-08-31 23:35:56 UTC (rev 21646)
@@ -28,6 +28,8 @@
package org.cytoscape.work;
+import java.util.NoSuchElementException;
+
import static org.junit.Assert.*;
import org.junit.Test;
@@ -75,6 +77,16 @@
final TaskIterator iter = new TaskIterator();
iter.remove();
}
+
+ @Test(expected=NoSuchElementException.class)
+ public final void testNext() throws Exception {
+ final Task initialTask = new SimpleTask(1);
+ final TaskIterator iter = new TaskIterator(initialTask);
+ assertNotNull("We should have gotten a task here!",
iter.next());
+
+ // This should blow up!
+ iter.next();
+ }
}
--
You received this message because you are subscribed to the Google Groups
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/cytoscape-cvs?hl=en.