diff options
author | Gav Wood <g@ethdev.com> | 2015-08-20 17:01:33 +0800 |
---|---|---|
committer | Gav Wood <g@ethdev.com> | 2015-08-20 17:01:33 +0800 |
commit | 38235cc9e14d442516a73b5a46260ad82255e3ff (patch) | |
tree | 39fd4a279c6aa7fefa314e10b615bc37137905d4 /test/boostTest.cpp | |
parent | 4c8b2202575b8c169b6dda9f81a0c6f171361df9 (diff) | |
parent | 8d9eb6830781cc107d09a92a59f71914a341ad3c (diff) | |
download | dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.tar dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.tar.gz dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.tar.bz2 dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.tar.lz dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.tar.xz dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.tar.zst dexon-solidity-38235cc9e14d442516a73b5a46260ad82255e3ff.zip |
Merge pull request #6 from chriseth/cmakeUpdateTests
Modularise CMakeLists files and integrate tests.
Diffstat (limited to 'test/boostTest.cpp')
-rw-r--r-- | test/boostTest.cpp | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/test/boostTest.cpp b/test/boostTest.cpp index f448c48e..f3400a31 100644 --- a/test/boostTest.cpp +++ b/test/boostTest.cpp @@ -25,68 +25,9 @@ #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wunused-parameter" //#define BOOST_DISABLE_WIN32 //disables SEH warning -#define BOOST_TEST_NO_MAIN #include <boost/test/included/unit_test.hpp> #pragma GCC diagnostic pop #include <test/TestHelper.h> using namespace boost::unit_test; -//Custom Boost Initialization -test_suite* init_func( int argc, char* argv[] ) -{ - if (argc == 0) - argv[1]=(char*)"a"; - - dev::test::Options::get(); - - return 0; -} - -//Custom Boost Unit Test Main -int main( int argc, char* argv[] ) -{ - try - { - framework::init( init_func, argc, argv ); - - if( !runtime_config::test_to_run().is_empty() ) - { - test_case_filter filter( runtime_config::test_to_run() ); - - traverse_test_tree( framework::master_test_suite().p_id, filter ); - } - - framework::run(); - - results_reporter::make_report(); - - return runtime_config::no_result_code() - ? boost::exit_success - : results_collector.results( framework::master_test_suite().p_id ).result_code(); - } - catch (framework::nothing_to_test const&) - { - return boost::exit_success; - } - catch (framework::internal_error const& ex) - { - results_reporter::get_stream() << "Boost.Test framework internal error: " << ex.what() << std::endl; - - return boost::exit_exception_failure; - } - catch (framework::setup_error const& ex) - { - results_reporter::get_stream() << "Test setup error: " << ex.what() << std::endl; - - return boost::exit_exception_failure; - } - catch (...) - { - results_reporter::get_stream() << "Boost.Test framework internal error: unknown reason" << std::endl; - - return boost::exit_exception_failure; - } - - return 0; -} |