diff options
author | thomasvl@gmail.com <thomasvl@gmail.com@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3> | 2009-01-30 15:17:34 +0000 |
---|---|---|
committer | thomasvl@gmail.com <thomasvl@gmail.com@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3> | 2009-01-30 15:17:34 +0000 |
commit | 2ae297214778005d95354f207753180edca51ec4 (patch) | |
tree | 137e6628c4b905693478e0f20f4912788e0a266e /UnitTesting/GTMIPhoneUnitTestDelegate.h | |
parent | ba7d45cf8c3b1938a51a9b3580919c61bf750f9d (diff) |
- Added simple accessor to get the number of tests that pass/fail from the
iphone test delegate, should make it easy for any app driving tests to check
the results for anything they need to do.
- If the iPhone unittesting support is exiting when done, it now properly sets
the exit code based on test success/failure.
Diffstat (limited to 'UnitTesting/GTMIPhoneUnitTestDelegate.h')
-rw-r--r-- | UnitTesting/GTMIPhoneUnitTestDelegate.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/UnitTesting/GTMIPhoneUnitTestDelegate.h b/UnitTesting/GTMIPhoneUnitTestDelegate.h index f12a9b6..4583b5d 100644 --- a/UnitTesting/GTMIPhoneUnitTestDelegate.h +++ b/UnitTesting/GTMIPhoneUnitTestDelegate.h @@ -21,11 +21,18 @@ // Application delegate that runs all test methods in registered classes // extending SenTestCase. The application is terminated afterwards. // You can also run the tests directly from your application by invoking -// gtm_runTests and clean up, restore data, etc. before the application +// runTests and clean up, restore data, etc. before the application // terminates. -@interface GTMIPhoneUnitTestDelegate : NSObject +@interface GTMIPhoneUnitTestDelegate : NSObject { + @private + NSUInteger totalFailures_; + NSUInteger totalSuccesses_; +} // Runs through all the registered classes and runs test methods on any // that are subclasses of SenTestCase. Prints results and run time to // the default output. - (void)runTests; +// Fetch the number of successes or failures from the last runTests. +- (NSUInteger)totalSuccesses; +- (NSUInteger)totalFailures; @end |