tests/testthat/test-keycap.R

context("keycap")

test_that("keycap refuses things", {
  expect_error( keycap( "grze" ) )
})

test_that("keycap keeps some metadata", {
  ten <- keycap(10)
  expect_equal( attr(ten, "char"), "10" )
})
hadley/emo documentation built on Dec. 16, 2019, 3:42 p.m.