context("test_get_split_format")
library(stringi)
fmt <- stri_c("p{1cm}p{2.5cm}p{1cm}p{1cm}p{2cm}p{1cm}p{6cm}p{1cm}p{2cm}")
test_that("get_split_format forms correct format statements", {
format <- get_split_format(fmt, cm = 15)
expect_equal(format$split_format[[1]], "p{0cm}p{1cm}p{2.5cm}p{1cm}p{1cm}p{2cm}p{1cm}")
expect_equal(format$cols[1, ], c(1, 6))
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.