andygrove opened a new pull request, #341:
URL: https://github.com/apache/datafusion-spark/pull/341

   ## Which issue does this PR close?
   
   - Follow-up to #72, adding the two optional tests suggested in review.
   
   ## Rationale for this change
   
   #72 was merged before the optional review suggestions were addressed. These 
tests guard two behaviors that are correct today: a NULL in any argument 
returns NULL before the other fields are checked, and the kernel respects array 
offsets when it is called directly, as Comet does.
   
   ## What changes are included in this PR?
   
   Tests only.
   
   - `datetime/make_time.slt`: table rows that pair a NULL with otherwise 
invalid fields, such as `(NULL, 60, 60)`, `(24, NULL, -0.5)` and `(24, 60, 
NULL)`. Each returns NULL. A valid row is included as a control.
   - `make_time.rs` unit tests:
     - `test_sliced_arrays` calls the kernel directly with sliced arrays that 
start at different offsets and have sliced null bitmaps. The invalid values sit 
outside the visible slices. The test checks the visible results, the NULL 
positions and the output length.
     - `test_empty_arrays` covers empty arrays and empty slices of arrays that 
hold invalid values.
   
   ## Are these changes tested?
   
   The new `.slt` rows were checked against Spark 4.2.0 with the PySpark 
runner, and every query in `make_time.slt` that it can run passes.
   
   ## Are there any user-facing changes?
   
   No.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to