tests/testthat/test-pitch-to-df.R

test_that("pitch_to_df", {
  file1 <- system.file("extdata", "test.Pitch", package = "phonfieldwork")
  file2 <- readLines(file1)

  expect_equal(nrow(pitch_to_df(file1)), 62)
  expect_equal(nrow(pitch_to_df(file2)), 62)
  expect_equal(nrow(pitch_to_df(file1, candidates = "all")), 426)
})
agricolamz/phonfieldwork documentation built on July 30, 2024, 8:51 p.m.