tests/testthat/test-cache.R

context("Cache")

test_that("Cache interface doesn't implement any public functions", {
  cache <- Cache$new()

  expect_error(cache$set(1, 1))
  expect_error(cache$get(1))
  expect_error(cache$delete(1))
  expect_error(cache$exists(1))
  expect_error(cache$trim())
  expect_error(cache$destroy())
})
skubicius/cashmere documentation built on May 22, 2019, 2:46 p.m.