| |
| |
| |
| |
| |
| |
| |
| #ifndef TWOBLUECUBES_CATCH_DEFAULT_MAIN_HPP_INCLUDED |
| #define TWOBLUECUBES_CATCH_DEFAULT_MAIN_HPP_INCLUDED |
|
|
| #include "catch_session.h" |
| #include "catch_platform.h" |
|
|
| #ifndef __OBJC__ |
|
|
| #if defined(CATCH_CONFIG_WCHAR) && defined(CATCH_PLATFORM_WINDOWS) && defined(_UNICODE) && !defined(DO_NOT_USE_WMAIN) |
| |
| extern "C" int wmain (int argc, wchar_t * argv[], wchar_t * []) { |
| #else |
| |
| int main (int argc, char * argv[]) { |
| #endif |
|
|
| return Catch::Session().run( argc, argv ); |
| } |
|
|
| #else |
|
|
| |
| int main (int argc, char * const argv[]) { |
| #if !CATCH_ARC_ENABLED |
| NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; |
| #endif |
|
|
| Catch::registerTestMethods(); |
| int result = Catch::Session().run( argc, (char**)argv ); |
|
|
| #if !CATCH_ARC_ENABLED |
| [pool drain]; |
| #endif |
|
|
| return result; |
| } |
|
|
| #endif |
|
|
| #endif |
|
|