                 );
             }
             
-            testMethods         = new ArrayIterator(testMethodsArray);
+            testMethods = new ArrayIterator(testMethodsArray);
+            setUpIterators(test);
+        }
+
+        private function setUpNullIterators():void {
+            // Set up null iterators for access to length
+            // and other properties...
+            testMethods        = new ArrayIterator();
+            beforeClassMethods = new ArrayIterator();
+            beforeMethods      = new ArrayIterator();
+            afterMethods       = new ArrayIterator();
+            afterClassMethods  = new ArrayIterator();
+            ignoredMethods     = new ArrayIterator();
+        }
+
+        private function setUpIterators(test:Object):void {
+            afterClassMethods   = new ArrayIterator(getAfterClassMethods(test));
+            afterMethods        = new ArrayIterator(getAfterMethods(test));
             beforeClassMethods  = new ArrayIterator(getBeforeClassMethods(test));
             beforeMethods       = new ArrayIterator(getBeforeMethods(test));
-            afterMethods        = new ArrayIterator(getAfterMethods(test));
-            afterClassMethods   = new ArrayIterator(getAfterClassMethods(test));
             ignoredMethods      = new ArrayIterator(getIgnoredMethods(test));
         }
 


    import p2.reflect.Reflection;
    import p2.reflect.ReflectionMethod;


    public class TestIterator implements Iterator {
        

            
            var testMethodsArray:Array = getTestMethods(test);
            if (!testMethodsArray.length) {
                setUpNullIterators();
                return;
            }
            
