Skip to content

Commit f7b6f62

Browse files
committed
Add test block11, comments.
1 parent 9335bc6 commit f7b6f62

2 files changed

Lines changed: 77 additions & 4 deletions

File tree

test/protocols/blocks.cpp

Lines changed: 76 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ const block bogus_block10
154154
{
155155
0x31323334,
156156
block9_hash,
157-
one_hash,
157+
hash_digest{ 0x10, 0xbb },
158158
0x41424344,
159159
0x51525354,
160160
0x61626364
@@ -198,14 +198,14 @@ const block bogus_block10
198198
{
199199
input
200200
{
201-
point{},
201+
point{ block1.transactions_ptr()->front()->hash(false), 0x00 },
202202
script{},
203203
witness{},
204204
0x07
205205
},
206206
input
207207
{
208-
point{},
208+
point{ block2.transactions_ptr()->front()->hash(false), 0x00 },
209209
script{},
210210
witness{},
211211
0x08
@@ -216,11 +216,13 @@ const block bogus_block10
216216
output
217217
{
218218
0x09,
219+
// "1BaMPFdqMUQ46BV8iRcwbVfsam57oBLMM"
219220
script::to_pay_key_hash_pattern({ 0x02 })
220221
},
221222
output
222223
{
223-
0x09,
224+
0x10,
225+
// "31xsx7sPoS2UfoUAKfoXLX6wTPvpetyo7s"
224226
script::to_pay_script_hash_pattern({ 0x03 })
225227
}
226228
},
@@ -258,6 +260,76 @@ const block bogus_block10
258260
}
259261
}
260262
};
263+
const block bogus_block11
264+
{
265+
header
266+
{
267+
0x31323334,
268+
block9_hash,
269+
hash_digest{ 0x12, 0xbb },
270+
0x41424344,
271+
0x51525354,
272+
0x61626364
273+
},
274+
transactions
275+
{
276+
transaction
277+
{
278+
0x07,
279+
inputs
280+
{
281+
input
282+
{
283+
point{ block3.transactions_ptr()->front()->hash(false), 0x00 },
284+
script{},
285+
witness{},
286+
0x08
287+
},
288+
input
289+
{
290+
point{ block4.transactions_ptr()->front()->hash(false), 0x00 },
291+
script{},
292+
witness{},
293+
0x09
294+
}
295+
},
296+
outputs
297+
{
298+
output
299+
{
300+
0x10,
301+
// "1BaMPFdqMUQ46BV8iRcwbVfsam57oBLMM"
302+
script::to_pay_key_hash_pattern({ 0x02 })
303+
},
304+
output
305+
{
306+
0x11,
307+
// "1BaMPFdqMUQ46BV8iRcwbVfsam57oBLMM"
308+
script::to_pay_key_hash_pattern({ 0x02 })
309+
},
310+
output
311+
{
312+
0x12,
313+
// "31xsx7sPoS2UfoUAKfoXLX6wTPvpetyo7s"
314+
script::to_pay_script_hash_pattern({ 0x03 })
315+
},
316+
output
317+
{
318+
0x13,
319+
// "31xsx7sPoS2UfoUAKfoXLX6wTPvpetyo7s"
320+
script::to_pay_script_hash_pattern({ 0x03 })
321+
},
322+
output
323+
{
324+
0x14,
325+
// "31xsx7sPoS2UfoUAKfoXLX6wTPvpetyo7s"
326+
script::to_pay_script_hash_pattern({ 0x03 })
327+
}
328+
},
329+
0x0a
330+
}
331+
}
332+
};
261333
const block bogus_block
262334
{
263335
header

test/protocols/blocks.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ extern const system::chain::block block7;
8585
extern const system::chain::block block8;
8686
extern const system::chain::block block9;
8787
extern const system::chain::block bogus_block10;
88+
extern const system::chain::block bogus_block11;
8889

8990
extern const system::chain::block bogus_block;
9091
extern const system::chain::block block1a;

0 commit comments

Comments
 (0)