nealrichardson commented on code in PR #13773:
URL: https://github.com/apache/arrow/pull/13773#discussion_r939644636


##########
r/tests/testthat/test-compute.R:
##########
@@ -109,6 +112,8 @@ test_that("register_scalar_function() adds a compute 
function to the registry",
       dplyr::collect(),
     tibble::tibble(a = 1L, b = 32.0)
   )
+
+  Sys.unsetenv("R_ARROW_COLLECT_WITH_UDF")

Review Comment:
   NBD but should this more properly go inside of `on.exit` above? like
   
   ```
   on.exit({
     unregister_binding("times_32", update_cache = TRUE)
     # TODO(ARROW-17178) remove the need for this!
     Sys.unsetenv("R_ARROW_COLLECT_WITH_UDF")
   })
   ```



##########
r/tests/testthat/test-compute.R:
##########
@@ -143,6 +148,9 @@ test_that("arrow_scalar_function() with bad return type 
errors", {
     call_function("times_32_bad_return_type_scalar", Array$create(1L)),
     "Expected return Array or Scalar with type 'double'"
   )
+
+  # TODO(ARROW-17178) remove the need for this!
+  Sys.unsetenv("R_ARROW_COLLECT_WITH_UDF")
 })
 
 test_that("register_user_defined_function() can register multiple kernels", {

Review Comment:
   ```suggestion
   test_that("register_scalar_function() can register multiple kernels", {
   ```



##########
r/tests/testthat/test-compute.R:
##########
@@ -143,6 +148,9 @@ test_that("arrow_scalar_function() with bad return type 
errors", {
     call_function("times_32_bad_return_type_scalar", Array$create(1L)),
     "Expected return Array or Scalar with type 'double'"
   )
+
+  # TODO(ARROW-17178) remove the need for this!
+  Sys.unsetenv("R_ARROW_COLLECT_WITH_UDF")
 })
 
 test_that("register_user_defined_function() can register multiple kernels", {

Review Comment:
   Also below



-- 
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]

Reply via email to