tests/testthat/test-current_health.R

library(testthat)
library(CNAIM)

context("current health")

# TODO: test more parameter combinations
test_that("current_health", {
  expect_equal(current_health(2, 3), 6)
  expect_equal(current_health(2, 3, reliability_factor = 20), 10)
  expect_equal(current_health(200, 300), 10)
})

Try the CNAIM package in your browser

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

CNAIM documentation built on Aug. 31, 2022, 9:13 a.m.