[EOSIO/eos] add testcase for #2195 (security delays) (#2417)

brianjohnson5972 commented on this pull request.

> @@ -923,6 +923,16 @@ BOOST_AUTO_TEST_CASE( link_delay_link_change_test ) { try {
liquid_balance = get_currency_balance(chain, N(tester2));
BOOST_REQUIRE_EQUAL(asset::from_string(“0.0000 CUR”), liquid_balance);

+ try {
+ chain.push_action(config::system_account_name, contracts::linkauth::get_name(), tester_account, fc::mutable_variant_object()
+ (“account”, “tester”)
+ (“code”, “currency”)
+ (“type”, “transfer”)
+ (“requirement”, “second”),
+ 30, 3);
+ BOOST_FAIL(“linkauth should have a min delay set by previous linkauth”);
+ } catch (…) { }

please add specific exception here and expected content (if it is used in more than one place). We don’t want to say this is passing if another exception is being thrown.

This post was last modified on April 16, 2018, 3:45 pm