HyukjinKwon commented on code in PR #48653:
URL: https://github.com/apache/arrow/pull/48653#discussion_r2650034284


##########
r/tests/testthat/test-compute-arith.R:
##########
@@ -71,8 +71,6 @@ test_that("Division", {
   expect_equal(a / 2 / 2, Array$create(c(1:4 / 2 / 2, NA_real_)))
   expect_equal(a %/% 2L %/% 2L, Array$create(c(0L, 0L, 0L, 1L, NA_integer_)))
   expect_equal(a / 0, Array$create(c(Inf, Inf, Inf, Inf, NA_real_)))
-  # TODO add tests for integer division %/% by 0
-  # see https://issues.apache.org/jira/browse/ARROW-14297

Review Comment:
   Oh actually, I believe they are already being tested above:
   
   ```
   ...
     expect_equal(a %/% 0, Array$create(c(Inf, Inf, Inf, Inf, NA_real_)))
   ...
     expect_equal(a %/% 0L, Array$create(rep(NA_integer_, 5)))
   ...
     expect_equal(b %/% 0, Array$create(c(Inf, Inf, Inf, Inf, NA_real_)))
     expect_equal(b %/% 0L, Array$create(c(Inf, Inf, Inf, Inf, NA_real_)))
   ...
   ```
   
   24689928da also added the zero tests into here. Let me fix the PR 
description!



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