message: Add coin serialize deserialize priv coin
diff: @@ -32,4 +32,27 @@ BOOST_AUTO_TEST_CASE(pubcoin_validate)
  BOOST_CHECK(pubcoin.validate());
  }
  +BOOST_AUTO_TEST_CASE(getter_setter_priv)
  +{
  + auto params = sigma::ParamsV3::get_default();
  +
  + sigma::PrivateCoinV3 privcoin(params);
  + sigma::PrivateCoinV3 new_privcoin(params);
  +
  + BOOST_CHECK(privcoin.getPublicCoin() != new_privcoin.getPublicCoin());
  + BOOST_CHECK(privcoin.getSerialNumber() != new_privcoin.getSerialNumber());
  + BOOST_CHECK(privcoin.getRandomness() != new_privcoin.getRandomness());
  + BOOST_CHECK(privcoin.getVersion() == new_privcoin.getVersion());
  +
  + new_privcoin.setPublicCoin(privcoin.getPublicCoin());
  + new_privcoin.setRandomness(privcoin.getRandomness());
  + new_privcoin.setSerialNumber(privcoin.getSerialNumber());
  + new_privcoin.setVersion(2);
  +
  + BOOST_CHECK(privcoin.getPublicCoin() == new_privcoin.getPublicCoin());
  + BOOST_CHECK(privcoin.getSerialNumber() == new_privcoin.getSerialNumber());
  + BOOST_CHECK(privcoin.getRandomness() == new_privcoin.getRandomness());
  + BOOST_CHECK(new_privcoin.getVersion() == 2);
  +}
  +
  BOOST_AUTO_TEST_SUITE_END()
  