846 {
847 std::vector<action_trace_v1> actions = {
848 {
849 {
850 1,
851 "receiver"_n, "contract"_n, "action"_n,
852 {{ "alice"_n, "active"_n }},
853 { 0x01, 0x01, 0x01, 0x01 },
854 },
855 { 0x05, 0x05, 0x05, 0x05 }
856 },
857 {
858 {
859 0,
860 "receiver"_n, "contract"_n, "action"_n,
861 {{ "alice"_n, "active"_n }},
862 { 0x00, 0x00, 0x00, 0x00 }
863 },
864 { 0x04, 0x04, 0x04, 0x04}
865 },
866 {
867 {
868 2,
869 "receiver"_n, "contract"_n, "action"_n,
870 {{ "alice"_n, "active"_n }},
871 { 0x02, 0x02, 0x02, 0x02 }
872 },
873 { 0x06, 0x06, 0x06, 0x06 }
874 }
875 };
876
878 "0000000000000000000000000000000000000000000000000000000000000001"_h,
879 actions,
881 10,
882 5,
883 { chain::signature_type() },
884 { chain::time_point(), 1, 0, 100, 50, 0 }
885 };
886
888 "b000000000000000000000000000000000000000000000000000000000000001"_h,
889 1,
890 "0000000000000000000000000000000000000000000000000000000000000000"_h,
891 chain::block_timestamp_type(0),
892 "bp.one"_n,
893 "0000000000000000000000000000000000000000000000000000000000000000"_h,
894 "0000000000000000000000000000000000000000000000000000000000000000"_h,
895 0,
896 std::vector<transaction_trace_v2> {
898 }
899 };
900
902 ("id", "b000000000000000000000000000000000000000000000000000000000000001")
903 ("number", 1)
904 ("previous_id", "0000000000000000000000000000000000000000000000000000000000000000")
905 ("status", "pending")
906 ("timestamp", "2000-01-01T00:00:00.000Z")
907 ("producer", "bp.one")
908 ("transaction_mroot", "0000000000000000000000000000000000000000000000000000000000000000")
909 ("action_mroot", "0000000000000000000000000000000000000000000000000000000000000000")
910 ("schedule_version", 0)
913 ("id", "0000000000000000000000000000000000000000000000000000000000000001")
916 ("global_sequence", 0)
917 ("receiver", "receiver")
918 ("account", "contract")
919 ("action", "action")
922 ("account", "alice")
923 ("permission", "active")
924 }))
925 ("data", "00000000")
926 ("return_value","04040404")
927 ,
929 ("global_sequence", 1)
930 ("receiver", "receiver")
931 ("account", "contract")
932 ("action", "action")
935 ("account", "alice")
936 ("permission", "active")
937 }))
938 ("data", "01010101")
939 ("return_value", "05050505")
940 ,
942 ("global_sequence", 2)
943 ("receiver", "receiver")
944 ("account", "contract")
945 ("action", "action")
948 ("account", "alice")
949 ("permission", "active")
950 }))
951 ("data", "02020202")
952 ("return_value", "06060606")
953 }))
954 ("status", "executed")
955 ("cpu_usage_us", 10)
956 ("net_usage_words", 5)
957 (
"signatures",
fc::variants({
"SIG_K1_111111111111111111111111111111111111111111111111111111111111111116uk5ne"}))
959 ("expiration", "1970-01-01T00:00:00")
960 ("ref_block_num", 1)
961 ("ref_block_prefix", 0)
962 ("max_net_usage_words", 100)
963 ("max_cpu_usage_ms", 50)
964 ("delay_sec", 0)
965 )
966 }))
967 ;
968
970 BOOST_TEST(height == 1);
972 };
973
974
976 return {};
977 };
978
979 fc::variant actual_response = get_block_trace( 1 );
980
981 BOOST_TEST(
to_kv(expected_response) ==
to_kv(actual_response), boost::test_tools::per_element());
982 }