Skip to content

Commit

Permalink
add merge tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ben-schwen committed Aug 25, 2022
1 parent f015eed commit 6ab44b0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions inst/tests/tests.Rraw
Original file line number Diff line number Diff line change
Expand Up @@ -18852,3 +18852,7 @@ if (test_nanotime) {
test(2239.21, rbind(x,y, fill = TRUE), data.table(a = c(1L, 2L), b=as.nanotime(c(0, NA))))
test(2239.22, rbind(y,x, fill = TRUE), data.table(a = c(2L, 1L), b=as.nanotime(c(NA, 0))))
}
x = data.table(a = 1L, b = as.Date("2020-01-01"))
y = data.table(a = 2L, b = NA)
test(2239.23, merge(x, y, by="a", all=TRUE), data.table(a=1:2, b.x=as.Date(c("2020-01-01", NA)), b.y=NA, key="a"))
test(2239.24, merge(y, x, by="a", all=TRUE), data.table(a=1:2, b.x=NA, key="a", b.y=as.Date(c("2020-01-01", NA))))

0 comments on commit 6ab44b0

Please sign in to comment.