Skip to content

Commit

Permalink
test: more test case
Browse files Browse the repository at this point in the history
  • Loading branch information
eitsupi committed Apr 15, 2024
1 parent 096fc22 commit 2c64e2b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/testthat/test-expr_string.R
Original file line number Diff line number Diff line change
Expand Up @@ -707,6 +707,13 @@ test_that("str$to_integer", {
)

expect_grepl_error(pl$lit("foo")$str$to_integer()$to_r(), "strict integer parsing failed for 1 value")

expect_identical(
pl$DataFrame(base = c(2, 10), str = "10")$select(
pl$col("str")$str$to_integer(base = "base")
)$to_list()[[1]],
c(2, 10)
)
})

test_that("str$reverse()", {
Expand Down

0 comments on commit 2c64e2b

Please sign in to comment.