tests/testthat/test-frequencyStats.R

test_that("inputs are correct", {
  expect_error(frequencyStats("string"), "Expecting a Wave object")
  expect_error(frequencyStats(1), "Expecting a Wave object")
})

test_that("plotting is ok", {
  data(sheep, package="seewave")
  expect_silent(frequencyStats(sheep, plot=TRUE))
})

Try the sonicscrewdriver package in your browser

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

sonicscrewdriver documentation built on Aug. 21, 2026, 5:15 p.m.