Exemple #1
0
 Session()
 : m_cli( makeCommandLineParser() ) {
     if( alreadyInstantiated ) {
         std::string msg = "Only one instance of Catch::Session can ever be used";
         std::cerr << msg << std::endl;
         throw std::logic_error( msg );
     }
     alreadyInstantiated = true;
 }
Exemple #2
0
 Session()
 : m_cli( makeCommandLineParser() ),
 debug((new(AUTORELEASE)DebugManagerCatch)->setLevel(DebugSeverity::info)->setFormat("%m"_S))
 {
     if( alreadyInstantiated ) {
         std::string msg = "Only one instance of Catch::Session can ever be used";
         Catch::cerr() << msg << std::endl;
         throw std::logic_error( msg );
     }
     alreadyInstantiated = true;
     BaseObject::recentObjects = new std::unordered_set<BaseObject*>;
 }