tests/testthat/test_list_of_types_maker.R

context("list_of_types_maker")
library(testthat)
library(hmi)

#test_check("hmi")

test_that("list_of_types_maker returns the correct list", {
  expect_equal(list_of_types_maker(iris),
               list(Sepal.Length = "cont", Sepal.Width = "semicont", Petal.Length = "cont", Petal.Width = "semicont", Species = "categorical"))
})

Try the hmi package in your browser

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

hmi documentation built on Oct. 23, 2020, 7:31 p.m.