Skip to content

Commit

Permalink
Merge pull request #45 from nutriverse:dev
Browse files Browse the repository at this point in the history
improve test coverage; fix #25
  • Loading branch information
ernestguevarra authored Feb 7, 2025
2 parents 98b1940 + 0c0b96d commit bfa34b8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
4 changes: 4 additions & 0 deletions tests/testthat/test-detect_mad.R
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,7 @@ test_that("`get_mad` function define the output values correctly", {
}

})

test_that("errors are produced as expected", {
expect_error(get_mad(NULL, 0, 1, 1, 0))
})
8 changes: 6 additions & 2 deletions tests/testthat/test-detect_milkmf.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@


library(riycf)


################################################################################
# Return result values check
Expand Down Expand Up @@ -59,3 +57,9 @@ test_that("`get_mmff` function define the output values correctly", {
}

})


test_that("errors are produced as expected", {
expect_error(get_mmff(0, 2, NULL))
expect_error(get_milk_frq(0, 0, 0, NULL))
})

0 comments on commit bfa34b8

Please sign in to comment.