| 111 | } |
| 112 | |
| 113 | std::tuple<bool, boost::thread *> RunCoin(int argc, char *argv[]) { |
| 114 | boost::thread *detectShutdownThread = NULL; |
| 115 | static boost::thread_group threadGroup; |
| 116 | SetupEnvironment(); |
| 117 | |
| 118 | bool fRet = AppInit(argc, argv, threadGroup); |
| 119 | |
| 120 | detectShutdownThread = new boost::thread(boost::bind(&DetectShutdownThread, &threadGroup)); |
| 121 | |
| 122 | if (!fRet) { |
| 123 | if (detectShutdownThread) detectShutdownThread->interrupt(); |
| 124 | Interrupt(); |
| 125 | threadGroup.interrupt_all(); |
| 126 | } |
| 127 | return std::make_tuple(fRet, detectShutdownThread); |
| 128 | } |
| 129 | |
| 130 | SysTestBase::SysTestBase() { |
| 131 | // todo Auto-generated constructor stub |
no test coverage detected