@@ -94,33 +94,33 @@ bool setup_ten_block_store(query_t& query) NOEXCEPT
9494 query.set (block7, database::context{ 0 , 7 , 0 }, false , false ) &&
9595 query.set (block8, database::context{ 0 , 8 , 0 }, false , false ) &&
9696 query.set (block9, database::context{ 0 , 9 , 0 }, false , false ) &&
97- query.push_confirmed (query.to_header (block1_hash), false ) &&
98- query.push_confirmed (query.to_header (block2_hash), false ) &&
99- query.push_confirmed (query.to_header (block3_hash), false ) &&
100- query.push_confirmed (query.to_header (block4_hash), false ) &&
101- query.push_confirmed (query.to_header (block5_hash), false ) &&
102- query.push_confirmed (query.to_header (block6_hash), false ) &&
103- query.push_confirmed (query.to_header (block7_hash), false ) &&
104- query.push_confirmed (query.to_header (block8_hash), false ) &&
105- query.push_confirmed (query.to_header (block9_hash), false );
97+ query.push_confirmed (query.to_header (block1_hash), true ) &&
98+ query.push_confirmed (query.to_header (block2_hash), true ) &&
99+ query.push_confirmed (query.to_header (block3_hash), true ) &&
100+ query.push_confirmed (query.to_header (block4_hash), true ) &&
101+ query.push_confirmed (query.to_header (block5_hash), true ) &&
102+ query.push_confirmed (query.to_header (block6_hash), true ) &&
103+ query.push_confirmed (query.to_header (block7_hash), true ) &&
104+ query.push_confirmed (query.to_header (block8_hash), true ) &&
105+ query.push_confirmed (query.to_header (block9_hash), true );
106106}
107107
108108bool setup_three_block_store (query_t & query) NOEXCEPT
109109{
110110 return query.initialize (genesis) &&
111111 query.set (block1, database::context{ 0 , 1 , 0 }, false , false ) &&
112112 query.set (block2, database::context{ 0 , 2 , 0 }, false , false ) &&
113- query.push_confirmed (query.to_header (block1_hash), false ) &&
114- query.push_confirmed (query.to_header (block2_hash), false );
113+ query.push_confirmed (query.to_header (block1_hash), true ) &&
114+ query.push_confirmed (query.to_header (block2_hash), true );
115115}
116116
117117bool setup_three_block_witness_store (query_t & query) NOEXCEPT
118118{
119119 return query.initialize (genesis) &&
120120 query.set (block1a, database::context{ 0 , 1 , 0 }, false , false ) &&
121121 query.set (block2a, database::context{ 0 , 2 , 0 }, false , false ) &&
122- query.push_confirmed (query.to_header (block1a.hash ()), false ) &&
123- query.push_confirmed (query.to_header (block2a.hash ()), false );
122+ query.push_confirmed (query.to_header (block1a.hash ()), true ) &&
123+ query.push_confirmed (query.to_header (block2a.hash ()), true );
124124}
125125
126126bool setup_three_block_confirmed_address_store (query_t & query) NOEXCEPT
@@ -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,122 @@ const block bogus_block10
258260 }
259261 }
260262};
263+ const block bogus_block11
264+ {
265+ header
266+ {
267+ 0x31323334 ,
268+ bogus_block10.hash (),
269+ hash_digest{ 0x11 , 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+ };
333+ const block bogus_block12
334+ {
335+ header
336+ {
337+ 0x31323334 ,
338+ bogus_block11.hash (),
339+ hash_digest{ 0x12 , 0xbb },
340+ 0x41424344 ,
341+ 0x51525354 ,
342+ 0x61626364
343+ },
344+ transactions
345+ {
346+ transaction
347+ {
348+ 0x07 ,
349+ inputs
350+ {
351+ input
352+ {
353+ point{ bogus_block11.transactions_ptr ()->front ()->hash (false ), 0x03 },
354+ script{},
355+ witness{},
356+ 0x08
357+ },
358+ input
359+ {
360+ point{ bogus_block11.transactions_ptr ()->front ()->hash (false ), 0x04 },
361+ script{},
362+ witness{},
363+ 0x09
364+ }
365+ },
366+ outputs
367+ {
368+ output
369+ {
370+ 0x10 ,
371+ // "1BaMPFdqMUQ46BV8iRcwbVfsam57oBLMM"
372+ script::to_pay_key_hash_pattern ({ 0x02 })
373+ }
374+ },
375+ 0x0a
376+ }
377+ }
378+ };
261379const block bogus_block
262380{
263381 header
0 commit comments