diff --git a/tests/testthat/test-compute-epanechnikov.R b/tests/testthat/test-compute-epanechnikov.R new file mode 100644 index 0000000..bab1cc9 --- /dev/null +++ b/tests/testthat/test-compute-epanechnikov.R @@ -0,0 +1,5 @@ +test_that("`compute_epanechnikov` works for a vector of valid input", { + x <- seq(-1.5, 1.5, 0.5) + results <- compute_epanechnikov(x) + expect_equal(results, c(0, 0, 9/16, 3/4, 9/16, 0, 0)) +})