Skip to content

Commit 8e29d59

Browse files
authored
add atime test for grouping by factor (encodings) (#7482)
* add atime test * fix atime test
1 parent b6ad1a4 commit 8e29d59

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

.ci/atime/tests.R

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,5 +286,19 @@ test.list <- atime::atime_test_list(
286286
Slow = "548410d23dd74b625e8ea9aeb1a5d2e9dddd2927", # Parent of the first commit in the PR (https://github.com/Rdatatable/data.table/commit/548410d23dd74b625e8ea9aeb1a5d2e9dddd2927)
287287
Fast = "c0b32a60466bed0e63420ec105bc75c34590865e"), # Commit in the PR (https://github.com/Rdatatable/data.table/pull/7144/commits) that uses a much faster implementation
288288

289-
tests=extra.test.list)
289+
# Regression introduced in #7404 (grouped by factor).
290+
"DT[by] max regression fixed in #7480" = atime::atime_test(
291+
N = as.integer(10^seq(3, 5, by=0.5)),
292+
setup = {
293+
dt = data.table(
294+
id = as.factor(rep(seq_len(N), each = 100L)),
295+
V1 = 1L
296+
)
297+
},
298+
expr = data.table:::`[.data.table`(dt, , base::max(V1, na.rm = TRUE), by = id),
299+
Before = "476de7e3",
300+
Regression = "6f49bf1",
301+
Fixed = "b6ad1a4",
302+
seconds.limit = 1),
303+
tests=extra.test.list)
290304
# nolint end: undesirable_operator_linter.

0 commit comments

Comments
 (0)