Add test to ensure spending keys always encode with 'SK' at beginning.

This commit is contained in:
Sean Bowe 2016-06-15 16:25:21 -06:00
parent 13039c5362
commit f0ae0b11fe
1 changed files with 4 additions and 0 deletions

View File

@ -198,6 +198,10 @@ BOOST_AUTO_TEST_CASE(zc_address_test)
{
CZCSpendingKey spendingkey(sk);
string sk_string = spendingkey.ToString();
BOOST_CHECK(sk_string[0] == 'S');
BOOST_CHECK(sk_string[1] == 'K');
CZCSpendingKey spendingkey2(sk_string);
SpendingKey sk2 = spendingkey2.Get();
BOOST_CHECK(sk.inner() == sk2.inner());