Nothing
# Run all tests in this script:
## testthat::test_file(file.path("tests", "testthat", "test-molec_wt.R"))
# Error testing
test_that("Only accepts correct inputs", {
expect_error(molec_wt())
expect_error(molec_wt(element = "not_element"))
expect_error(molec_wt(element = 119))
})
# Output testing
test_that("Outputs are correct", {
expect_equal(molec_wt(element = "Oxygen"), 15.999)
expect_equal(molec_wt(element = "hydrogen"), 1.007)
expect_equal(molec_wt(element = "plutonium"), 244)
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.