tests/testthat/test-general.R

# library(testthat)
# library(dendextend)

context("General functions")


test_that("all.unique works", {
  expect_true(all_unique(c(1:10)))
  expect_true(all_unique(c(1, 3, 2)))
  expect_false(all_unique(c(1, 1, 2)))
  expect_false(all_unique(c(1:5, 1, 1)))
})

Try the dendextend package in your browser

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

dendextend documentation built on March 31, 2023, 10:17 p.m.