CMS 3D CMS Logo

Macros | Functions
TestHelper.h File Reference

Go to the source code of this file.

Macros

#define RUNTEST()   extern "C" char** environ; int main(int argc, char* argv[]) { return ptomaine(argc, argv, environ); }
 

Functions

int ptomaine (int argc, char *argv[], char **env)
 

Macro Definition Documentation

#define RUNTEST ( )    extern "C" char** environ; int main(int argc, char* argv[]) { return ptomaine(argc, argv, environ); }

Definition at line 29 of file TestHelper.h.

Function Documentation

int ptomaine ( int  argc,
char *  argv[],
char **  env 
)

Definition at line 177 of file TestHelper.cc.

References MessageLogger_cfi::cerr, do_work(), cppFunctionSkipper::exception, and x().

177  {
178  int rc = 1;
179  try {
180  rc = do_work(argc, argv, env);
181  }
182  catch(edm::Exception& x) {
183  std::cerr << "Caught an edm::Exception in "
184  << argv[0] << '\n'
185  << x;
186  }
187  catch(cms::Exception& x) {
188  std::cerr << "Caught a cms::Exception in "
189  << argv[0] << '\n'
190  << x;
191  }
192  catch(std::exception& x) {
193  std::cerr << "Caught a std::exception in "
194  << argv[0] << '\n'
195  << x.what();
196  }
197  catch(...) {
198  std::cerr << "Caught an unknown exception in "
199  << argv[0];
200  }
201  return rc;
202 }
int do_work(int argc, char *argv[], char **env)
Definition: TestHelper.cc:57
T x() const
Cartesian x coordinate.