tests/testthat/test-function.R

context("Functions")

test_that("function definitions work", {

  f <- function() function() "foo"
  expect_equal(cyclocomp(f), 1)

  f <- function() function(ok) ok
  expect_equal(cyclocomp(f), 1)
})
MangoTheCat/cyclocomp documentation built on July 12, 2021, 1:18 a.m.