@@ -479,6 +479,7 @@ mod tests {
479479 use std:: sync:: LazyLock ;
480480
481481 use rstest:: rstest;
482+ use vortex_array:: ExecutionCtx ;
482483 use vortex_array:: ToCanonical ;
483484 use vortex_array:: VectorExecutor ;
484485 use vortex_array:: arrays:: PrimitiveArray ;
@@ -505,7 +506,10 @@ mod tests {
505506 let values = PrimitiveArray :: from_iter ( ( 0 ..size) . map ( |i| i as f32 ) ) ;
506507 let encoded = alp_encode ( & values, None ) . unwrap ( ) ;
507508
508- let result_canonical = encoded. to_array ( ) . execute_session ( & SESSION ) . unwrap ( ) ;
509+ let result_canonical = {
510+ let mut ctx = ExecutionCtx :: new ( SESSION . clone ( ) ) ;
511+ encoded. to_array ( ) . execute ( & mut ctx) . unwrap ( )
512+ } ;
509513 // Compare against the traditional array-based decompress path
510514 let expected = decompress_into_array ( encoded) ;
511515
@@ -532,7 +536,10 @@ mod tests {
532536 let values = PrimitiveArray :: from_iter ( ( 0 ..size) . map ( |i| i as f64 ) ) ;
533537 let encoded = alp_encode ( & values, None ) . unwrap ( ) ;
534538
535- let result_canonical = encoded. to_array ( ) . execute_session ( & SESSION ) . unwrap ( ) ;
539+ let result_canonical = {
540+ let mut ctx = ExecutionCtx :: new ( SESSION . clone ( ) ) ;
541+ encoded. to_array ( ) . execute ( & mut ctx) . unwrap ( )
542+ } ;
536543 // Compare against the traditional array-based decompress path
537544 let expected = decompress_into_array ( encoded) ;
538545
@@ -565,7 +572,10 @@ mod tests {
565572 let encoded = alp_encode ( & array, None ) . unwrap ( ) ;
566573 assert ! ( encoded. patches( ) . unwrap( ) . array_len( ) > 0 ) ;
567574
568- let result_canonical = encoded. to_array ( ) . execute_session ( & SESSION ) . unwrap ( ) ;
575+ let result_canonical = {
576+ let mut ctx = ExecutionCtx :: new ( SESSION . clone ( ) ) ;
577+ encoded. to_array ( ) . execute ( & mut ctx) . unwrap ( )
578+ } ;
569579 // Compare against the traditional array-based decompress path
570580 let expected = decompress_into_array ( encoded) ;
571581
@@ -596,7 +606,10 @@ mod tests {
596606 let array = PrimitiveArray :: from_option_iter ( values) ;
597607 let encoded = alp_encode ( & array, None ) . unwrap ( ) ;
598608
599- let result_canonical = encoded. to_array ( ) . execute_session ( & SESSION ) . unwrap ( ) ;
609+ let result_canonical = {
610+ let mut ctx = ExecutionCtx :: new ( SESSION . clone ( ) ) ;
611+ encoded. to_array ( ) . execute ( & mut ctx) . unwrap ( )
612+ } ;
600613 // Compare against the traditional array-based decompress path
601614 let expected = decompress_into_array ( encoded) ;
602615
@@ -638,7 +651,10 @@ mod tests {
638651 let encoded = alp_encode ( & array, None ) . unwrap ( ) ;
639652 assert ! ( encoded. patches( ) . unwrap( ) . array_len( ) > 0 ) ;
640653
641- let result_canonical = encoded. to_array ( ) . execute_session ( & SESSION ) . unwrap ( ) ;
654+ let result_canonical = {
655+ let mut ctx = ExecutionCtx :: new ( SESSION . clone ( ) ) ;
656+ encoded. to_array ( ) . execute ( & mut ctx) . unwrap ( )
657+ } ;
642658 // Compare against the traditional array-based decompress path
643659 let expected = decompress_into_array ( encoded) ;
644660
@@ -683,7 +699,10 @@ mod tests {
683699 let slice_len = slice_end - slice_start;
684700 let sliced_encoded = encoded. slice ( slice_start..slice_end) ;
685701
686- let result_canonical = sliced_encoded. execute_session ( & SESSION ) . unwrap ( ) ;
702+ let result_canonical = {
703+ let mut ctx = ExecutionCtx :: new ( SESSION . clone ( ) ) ;
704+ sliced_encoded. execute ( & mut ctx) . unwrap ( )
705+ } ;
687706 let result_primitive = result_canonical. into_primitive ( ) ;
688707
689708 for idx in 0 ..slice_len {
0 commit comments