Fix 2 of the failing tests
This commit is contained in:
parent
609f5a746e
commit
1c8e31c34a
3 changed files with 2 additions and 5 deletions
|
|
@ -21,7 +21,6 @@ public:
|
||||||
database& d = db();
|
database& d = db();
|
||||||
balance = &op.balance_to_claim(d);
|
balance = &op.balance_to_claim(d);
|
||||||
|
|
||||||
|
|
||||||
FC_ASSERT(trx_state->signed_by( balance->owner, true /*maybe pts*/ ));
|
FC_ASSERT(trx_state->signed_by( balance->owner, true /*maybe pts*/ ));
|
||||||
FC_ASSERT(op.total_claimed.asset_id == balance->asset_type());
|
FC_ASSERT(op.total_claimed.asset_id == balance->asset_type());
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -381,13 +381,13 @@ BOOST_AUTO_TEST_CASE( genesis_authority )
|
||||||
sign(trx, key_id_type(), genesis_key);
|
sign(trx, key_id_type(), genesis_key);
|
||||||
BOOST_CHECK_THROW(PUSH_TX( db, trx ), fc::exception);
|
BOOST_CHECK_THROW(PUSH_TX( db, trx ), fc::exception);
|
||||||
|
|
||||||
auto sign = [&] { trx.signatures.clear(); trx.sign(nathan_key_id,nathan_key); };
|
auto sign = [&] { trx.signatures.clear(); trx.sign(nathan_key); };
|
||||||
|
|
||||||
proposal_create_operation pop;
|
proposal_create_operation pop;
|
||||||
pop.proposed_ops.push_back({trx.operations.front()});
|
pop.proposed_ops.push_back({trx.operations.front()});
|
||||||
pop.expiration_time = db.head_block_time() + global_params.genesis_proposal_review_period*2;
|
pop.expiration_time = db.head_block_time() + global_params.genesis_proposal_review_period*2;
|
||||||
pop.fee_paying_account = nathan.id;
|
pop.fee_paying_account = nathan.id;
|
||||||
trx.operations.back() = pop;
|
trx.operations = {pop};
|
||||||
sign();
|
sign();
|
||||||
|
|
||||||
// The review period isn't set yet. Make sure it throws.
|
// The review period isn't set yet. Make sure it throws.
|
||||||
|
|
@ -480,7 +480,6 @@ BOOST_FIXTURE_TEST_CASE( fired_delegates, database_fixture )
|
||||||
pop.expiration_time = db.head_block_time() + *pop.review_period_seconds * 3;
|
pop.expiration_time = db.head_block_time() + *pop.review_period_seconds * 3;
|
||||||
pop.proposed_ops.emplace_back(transfer_operation({asset(),account_id_type(), nathan->id, asset(100000)}));
|
pop.proposed_ops.emplace_back(transfer_operation({asset(),account_id_type(), nathan->id, asset(100000)}));
|
||||||
trx.operations.push_back(pop);
|
trx.operations.push_back(pop);
|
||||||
sign(trx, key_id_type(), genesis_key);
|
|
||||||
const proposal_object& prop = db.get<proposal_object>(PUSH_TX( db, trx ).operation_results.front().get<object_id_type>());
|
const proposal_object& prop = db.get<proposal_object>(PUSH_TX( db, trx ).operation_results.front().get<object_id_type>());
|
||||||
proposal_id_type pid = prop.id;
|
proposal_id_type pid = prop.id;
|
||||||
BOOST_CHECK(!pid(db).is_authorized_to_execute(db));
|
BOOST_CHECK(!pid(db).is_authorized_to_execute(db));
|
||||||
|
|
|
||||||
|
|
@ -349,7 +349,6 @@ BOOST_AUTO_TEST_CASE( switch_forks_undo_create )
|
||||||
cop.name = "nathan";
|
cop.name = "nathan";
|
||||||
cop.owner = authority(1, key_id_type(), 1);
|
cop.owner = authority(1, key_id_type(), 1);
|
||||||
trx.operations.push_back(cop);
|
trx.operations.push_back(cop);
|
||||||
trx.sign( key_id_type(), delegate_priv_key );
|
|
||||||
PUSH_TX( db1, trx );
|
PUSH_TX( db1, trx );
|
||||||
|
|
||||||
auto aw = db1.get_global_properties().active_witnesses;
|
auto aw = db1.get_global_properties().active_witnesses;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue