@@ -96,6 +96,9 @@ func TestProverTestSuite(t *testing.T) {
9696}
9797
9898func (ts * ProverTestSuite ) SetupTest () {
99+ err := log .InitLogger ("DEBUG" , "text" , "stdout" )
100+ ts .Require ().NoError (err )
101+
99102 signerConfig := & hd.SignerConfig {
100103 Mnemonic : "math razor capable expose worth grape metal sunset metal sudden usage scheme" ,
101104 Path : "m/44'/60'/0'/0/0" ,
@@ -113,9 +116,6 @@ func (ts *ProverTestSuite) SetupTest() {
113116 err = chain .Init ("" , 0 , codec , false )
114117 ts .Require ().NoError (err )
115118
116- err = log .InitLogger ("DEBUG" , "text" , "stdout" )
117- ts .Require ().NoError (err )
118-
119119 err = chain .SetRelayInfo (& core.PathEnd {
120120 ClientID : "mock-client-0" ,
121121 ConnectionID : "connection-0" ,
@@ -162,8 +162,13 @@ func (ts *ProverTestSuite) TestQueryClientStateWithProof() {
162162 ts .Require ().Equal (proofHeight .GetRevisionNumber (), uint64 (0 ))
163163 ts .Require ().Equal (proofHeight .GetRevisionHeight (), uint64 (21400 ))
164164
165+ decoded := ProveState {}
166+ ts .Require ().NoError (decoded .Unmarshal (proof ))
167+
168+ expected , _ := ts .chain .GetProof (common.Address {}, nil , nil )
169+ ts .Require ().Equal (common .Bytes2Hex (decoded .AccountProof ), common .Bytes2Hex (expected .AccountProofRLP ))
165170 // storage_key is 0x0c0dd47e5867d48cad725de0d09f9549bd564c1d143f6c1f451b26ccd981eeae
166- ts .Require ().Equal (common .Bytes2Hex (proof ), "f853f8518080a0143145e818eeff83817419a6632ea193fd1acaa4f791eb17282f623f38117f568080808080808080a016cbf6e0ba10512eb618d99a1e34025adb7e6f31d335bda7fb20c8bb95fb5b978080808080" )
171+ ts .Require ().Equal (common .Bytes2Hex (decoded . CommitmentProof ), "f853f8518080a0143145e818eeff83817419a6632ea193fd1acaa4f791eb17282f623f38117f568080808080808080a016cbf6e0ba10512eb618d99a1e34025adb7e6f31d335bda7fb20c8bb95fb5b978080808080" )
167172}
168173
169174func (ts * ProverTestSuite ) TestConnection () {
0 commit comments