tests/testthat/test_getMeanWordLength.R

context("getMeanWordLength")

test_that("Mean word length is computed correctly", {
    text = "Do you want the mustache on or off"
    expect_equal(getMeanWordLength(text), 3.375)
})
cw25/opencpu_service_ci_tutorial documentation built on Jan. 4, 2021, 2:54 a.m.