tests/testthat/test-tidyr.R

context("tidyr")

library(tidyr)

test_that("gather properly gathers columns", {
    gTheoph <- Theoph %>% gather(key, value, -Subject)
    expect_true(all(unique(gTheoph$key) %in% c("Wt", "Dose", "Time", "conc")))
})
dpastoor/phmxversecore documentation built on May 15, 2019, 1:22 p.m.