| 1 |
test_that("dim2() falls back to vec_size()", { |
| 2 |
expect_equal(dim2(1:3), 3) |
| 3 |
expect_equal(dim2(Titanic), dim(Titanic)) |
| 4 |
}) |
| 5 |
|
| 6 |
test_that("Using perceived dimensions (#167)", { |
| 7 |
expect_equal(dim_desc(as.POSIXlt(Sys.time() + 1:10)), "10") |
| 8 |
expect_equal(dim_desc(as.POSIXlt(Sys.time() + 1:17)), "17") |
| 9 |
}) |
| 10 |
|
| 11 |
test_that("big_mark() works for large numbers", { |
| 12 |
expect_match(big_mark(123), "123") |
| 13 |
expect_match(big_mark(123456), "123.456") |
| 14 |
expect_match(big_mark(123456789), "123.456.789") |
| 15 |
}) |