Debian Codegraph @

tests/testthat/test-ctl_new_pillar.R

raw
1 test_that("ctl_new_pillar()", {
2 expect_snapshot({
3 ctl_new_pillar(new_tbl(), 1:3, width = 20, title = "a")
4 })
5 })
6
7 test_that("ctl_new_pillar_list()", {
8 expect_snapshot({
9 ctl_new_pillar_list(new_tbl(), 1:3, width = 20, title = "a")
10 ctl_new_pillar_list(new_tbl(), trees[1:3, ], width = 8, title = "a")
11 ctl_new_pillar_list(new_tbl(), trees[1:3, ], width = 20, title = "a")
12 ctl_new_pillar_list(new_tbl(), as.matrix(trees[1:3, ]), width = 8, title = "a")
13 ctl_new_pillar_list(new_tbl(), as.matrix(trees[1:3, ]), width = 20, title = "a")
14 ctl_new_pillar_list(new_tbl(), matrix(1:6, ncol = 2), width = 8, title = "a")
15 ctl_new_pillar_list(new_tbl(), matrix(1:6, ncol = 2), width = 20, title = "a")
16 ctl_new_pillar_list(new_tbl(), matrix(1:6, ncol = 3), width = 10, title = "a")
17 })
18 })
19
20 test_that("ctl_new_pillar_list() for tables", {
21 skip_if_not_installed("vctrs", "0.3.6.9000")
22 expect_snapshot({
23 ctl_new_pillar_list(new_tbl(), Titanic, width = 20, title = "a")
24 })
25 })