LEFT | RIGHT |
(no file at all) | |
1 // Copyright 2006--2019 Rutger E.W. van Beusekom. | 1 // Copyright 2006--2019 Rutger E.W. van Beusekom. |
2 // Distributed under the Boost Software License, Version 1.0. (See | 2 // Distributed under the Boost Software License, Version 1.0. (See |
3 // accompanying file LICENSE_1_0.txt or copy at | 3 // accompanying file LICENSE_1_0.txt or copy at |
4 // http://www.boost.org/LICENSE_1_0.txt) | 4 // http://www.boost.org/LICENSE_1_0.txt) |
5 | 5 |
6 #ifndef __YAFFUT_H__ | 6 #ifndef __YAFFUT_H__ |
7 #define __YAFFUT_H__ | 7 #define __YAFFUT_H__ |
8 | 8 |
9 #include "config.hh" | 9 #include "config.hh" |
10 #if HAVE_CXA_DEMANGLE | 10 #if HAVE_CXA_DEMANGLE |
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
226 << " != actual: " << "(" << demangle<Actual>() << ") " << a; | 226 << " != actual: " << "(" << demangle<Actual>() << ") " << a; |
227 failure_ = os.str (); | 227 failure_ = os.str (); |
228 } | 228 } |
229 failure (const char *at = "", const char *expr = "") | 229 failure (const char *at = "", const char *expr = "") |
230 { | 230 { |
231 std::ostringstream os; | 231 std::ostringstream os; |
232 os << at << expr; | 232 os << at << expr; |
233 failure_ = os.str (); | 233 failure_ = os.str (); |
234 } | 234 } |
235 virtual ~failure () throw () {} | 235 virtual ~failure () throw () {} |
236 virtual const char *what () const throw () { return failure_.c_str (); } | 236 const char *what () const throw () override { return failure_.c_str (); } |
237 }; | 237 }; |
238 | 238 |
239 template <typename Suite, typename Case> | 239 template <typename Suite, typename Case> |
240 struct Registrator | 240 struct Registrator |
241 { | 241 { |
242 Registrator () | 242 Registrator () |
243 { | 243 { |
244 Factory::Instance ().Register (TestName (), Create); | 244 Factory::Instance ().Register (TestName (), Create); |
245 } | 245 } |
246 const std::string &TestName () | 246 const std::string &TestName () |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
401 { | 401 { |
402 std::cout << "pid(" << getpid () << ")" << std::endl; | 402 std::cout << "pid(" << getpid () << ")" << std::endl; |
403 return yaffut::Factory::Instance ().Main (argc, argv); | 403 return yaffut::Factory::Instance ().Main (argc, argv); |
404 }; | 404 }; |
405 | 405 |
406 #endif /* YAFFUT_MAIN */ | 406 #endif /* YAFFUT_MAIN */ |
407 | 407 |
408 #define yaffut_main(argc, argv) yaffut::Factory::Instance().Main (argc, argv) | 408 #define yaffut_main(argc, argv) yaffut::Factory::Instance().Main (argc, argv) |
409 | 409 |
410 #endif | 410 #endif |
LEFT | RIGHT |