tests/testthat/test-formatting-props.R

context("formatting properties")

test_that("text properties", {
  tp <- textProperties(color="red", font.weight = "bold",
                       font.style = "italic", underlined = TRUE )
  tp_ <- chprop(tp, font.weight = "normal")
  expect_equal(tp_$font.weight, "normal" )
})

test_that("par properties", {
  pp <- parRight( )
  expect_equal(pp$text.align, "right" )
  pp <- parLeft( )
  expect_equal(pp$text.align, "left" )
  pp_ <- chprop(pp, text.align = "center")
  expect_equal(pp_$text.align, "center" )
})

Try the ReporteRs package in your browser

Any scripts or data that you put into this service are public.

ReporteRs documentation built on April 1, 2018, 12:06 p.m.