You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "jonkeane (via GitHub)" <gi...@apache.org> on 2025/06/02 14:50:49 UTC

Re: [PR] GH-44208: [R] Adding test to ensure bit64's new semantic works with arrow [arrow]

jonkeane commented on code in PR #46651:
URL: https://github.com/apache/arrow/pull/46651#discussion_r2121386114


##########
r/tests/testthat/test-Array.R:
##########
@@ -352,6 +352,20 @@ test_that("array supports integer64", {
   expect_true(as.vector(is.na(all_na)))
 })
 
+test_that("array supports integer64 with new sematics", {
+  options(integer64_semantics="new")

Review Comment:
   Would you mind wrapping this in `withr::with_options(list(integer64_semantics = "new"), {...}`
   
   see https://github.com/apache/arrow/blob/c2fb0e3500ff73662275eeab9e96abc5d3090d82/r/tests/testthat/test-Array.R#L842 for an example. This will ensure the option isn't kept on after.



##########
r/tests/testthat/test-Array.R:
##########
@@ -352,6 +352,20 @@ test_that("array supports integer64", {
   expect_true(as.vector(is.na(all_na)))
 })
 
+test_that("array supports integer64 with new sematics", {
+  options(integer64_semantics="new")
+  x <- bit64::as.integer64(1:10) + MAX_INT 

Review Comment:
   ```suggestion
     x <- bit64::as.integer64(1:10) + MAX_INT
   ```



-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org