Fix #15 - adding unit test

This commit is contained in:
Daniel Larimer 2015-06-19 16:18:56 -04:00
parent 5d5604f673
commit fdec2a24e3

View file

@ -41,6 +41,15 @@ using namespace graphene::db;
BOOST_FIXTURE_TEST_SUITE( basic_tests, database_fixture )
/** verify that names are
* https://github.com/cryptonomex/graphene/issues/15
*/
BOOST_AUTO_TEST_CASE( valid_name_test )
{
BOOST_REQUIRE( is_valid_name( "aaa-bbb-1" ) );
BOOST_REQUIRE( !is_valid_name( "1aaa-bbb" ) );
}
BOOST_AUTO_TEST_CASE( price_test )
{
BOOST_CHECK( price::max(0,1) > price::min(0,1) );