tests/testthat/test_diet.R

context("diet")

diet1 <- get_diet("2009/2010", day = "first")
diet2 <- get_diet("2009/2010", day = "second")
diet3 <- get_diet("2009/2010", day = "both")

test_that("get_diet returns data frames", {

    expect_is(diet1, "data.frame")
    expect_is(diet2, "data.frame")
    expect_is(diet3, "data.frame")

})

Try the hei package in your browser

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

hei documentation built on Aug. 18, 2017, 1:03 a.m.