      }
 Index: ports/classes/net/xp_framework/unittest/tests/SimpleTestCase.class.php
 ===================================================================
---- ports/classes/net/xp_framework/unittest/tests/SimpleTestCase.class.php	(revision 11672)
+--- ports/classes/net/xp_framework/unittest/tests/SimpleTestCase.class.php	(revision 11673)
 +++ ports/classes/net/xp_framework/unittest/tests/SimpleTestCase.class.php	(working copy)
 @@ -15,6 +15,30 @@
     * @purpose  Unit Test

+          // Call afterClass method of the last test's class
+          if ($current) foreach ($current->getMethods() as $m) {
+            if (!$m->hasAnnotation('afterClass')) continue;
+            $m->invoke(NULL, array());
+            break;
+          }
+        

     }
     
     /**
@@ -279,15 +285,49 @@
      *
      * @param   unittest.TestCase test
      * @return  unittest.TestResult
