|
1 | 1 | use fil_actor_multisig::testing::check_state_invariants;
|
2 | 2 | use fil_actor_multisig::{
|
3 |
| - compute_proposal_hash, Actor as MultisigActor, ConstructorParams, Method, ProposeParams, |
4 |
| - ProposeReturn, State, Transaction, TxnID, TxnIDParams, SIGNERS_MAX, |
| 3 | + compute_proposal_hash, Actor as MultisigActor, ConstructorParams, Method, ProposeReturn, State, |
| 4 | + Transaction, TxnID, TxnIDParams, SIGNERS_MAX, |
5 | 5 | };
|
6 | 6 | use fil_actors_runtime::cbor::serialize;
|
7 | 7 | use fil_actors_runtime::runtime::Runtime;
|
@@ -123,7 +123,7 @@ mod constructor_tests {
|
123 | 123 | RawBytes::default(),
|
124 | 124 | rt.call::<MultisigActor>(
|
125 | 125 | Method::Constructor as u64,
|
126 |
| - IpldBlock::serialize_cbor(¶ms).unwrap() |
| 126 | + IpldBlock::serialize_cbor(¶ms).unwrap(), |
127 | 127 | )
|
128 | 128 | .unwrap()
|
129 | 129 | );
|
@@ -748,50 +748,6 @@ fn test_fail_propose_from_non_signer() {
|
748 | 748 | check_state(&rt);
|
749 | 749 | }
|
750 | 750 |
|
751 |
| -#[test] |
752 |
| -fn test_propose_restricted_correctly() { |
753 |
| - let msig = Address::new_id(1000); |
754 |
| - let mut rt = construct_runtime(msig); |
755 |
| - let h = util::ActorHarness::new(); |
756 |
| - |
757 |
| - let anne = Address::new_id(101); |
758 |
| - // We will treat Bob as having code CID b"102" |
759 |
| - let bob = Address::new_id(102); |
760 |
| - let chuck = Address::new_id(103); |
761 |
| - let no_unlock_duration = 0; |
762 |
| - let start_epoch = 0; |
763 |
| - let signers = vec![anne, bob]; |
764 |
| - |
765 |
| - let send_value = TokenAmount::from_atto(10u8); |
766 |
| - h.construct_and_verify(&mut rt, 2, no_unlock_duration, start_epoch, signers); |
767 |
| - |
768 |
| - // set caller to not-builtin |
769 |
| - rt.set_caller(make_identity_cid(b"102"), Address::new_id(102)); |
770 |
| - let propose_params = IpldBlock::serialize_cbor(&ProposeParams { |
771 |
| - to: chuck, |
772 |
| - value: send_value, |
773 |
| - method: METHOD_SEND, |
774 |
| - params: RawBytes::default(), |
775 |
| - }) |
776 |
| - .unwrap(); |
777 |
| - |
778 |
| - // cannot call the unexported method num |
779 |
| - |
780 |
| - expect_abort_contains_message( |
781 |
| - ExitCode::USR_FORBIDDEN, |
782 |
| - "must be built-in", |
783 |
| - rt.call::<MultisigActor>(Method::Propose as u64, propose_params.clone()), |
784 |
| - ); |
785 |
| - |
786 |
| - rt.verify(); |
787 |
| - |
788 |
| - // can call the exported method num |
789 |
| - rt.expect_validate_caller_any(); |
790 |
| - rt.call::<MultisigActor>(Method::ProposeExported as u64, propose_params).unwrap(); |
791 |
| - |
792 |
| - rt.verify(); |
793 |
| -} |
794 |
| - |
795 | 751 | // AddSigner
|
796 | 752 | #[test]
|
797 | 753 | fn test_add_signer() {
|
|
0 commit comments