def test_get_chain_id(self): lcc.set_step("Get chain id") self.send_request(self.get_request(self.__get_chain_id), self.__identifier) self.__resp = self.get_response() lcc.set_step("Check chain id info") check_that( "'chain id'", self.__resp["result"], is_str(self.get_expected(self.__get_chain_id)), )
def test_get_dynamic_global_properties(self): lcc.set_step("Get dynamic global properties") self.send_request( self.get_request(self.__get_dynamic_global_properties), self.__identifier) self.__resp = self.get_response() lcc.set_step("Check dynamic global properties info") check_that_in( self.__resp["result"], "id", is_str("2.1.0"), )
def test_get_transaction_hex(self): lcc.set_step("Get transaction hex") self.send_request( self.get_request(self.__get_transaction_hex, [self.get_expected(self.__get_transaction)]), self.__identifier) self.__resp = self.get_response() lcc.set_step("Check get transaction hex") check_that( "'transaction hex'", self.__resp["result"], is_str(self.get_expected(self.__get_transaction_hex)), )
def test_call_contract_no_changing_state(self): lcc.set_step("Get contract") self.send_request( self.get_request(self.__call_contract_no_changing_state), self.__identifier) self.__resp = self.get_response() lcc.set_step("Check call contract no changing state") check_that( "'method call'", self.__resp["result"], is_str( "000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000" "0000000000000000000000000000000e48656c6c6f20576f726c64212121000000000000000000000000000000000000" ), )
def test_get_witness_by_account(self): lcc.set_step("Get witness by account") self.send_request(self.get_request(self.__get_witness_by_account), self.__identifier) self.__resp = self.get_response() lcc.set_step("Check witness by account") check_that_in( self.__resp["result"], "id", is_str("1.6.0"), "witness_account", is_str("1.2.0"), "last_aslot", is_integer(), "signing_key", is_str("ECHO1111111111111111111111111111111114T1Anm"), "pay_vb", is_str("1.13.1"), "vote_id", is_str("1:0"), "total_votes", is_integer(0), "url", is_str(""), "total_missed", is_integer(0), "last_confirmed_block_num", is_integer(), "ed_signing_key", is_str( "0000000000000000000000000000000000000000000000000000000000000000" ))