powered by
throws_error(regexp)
expect_that(log("a"), throws_error()) expect_error(log("a")) expect_that(log("a"), throws_error("Non-numeric argument")) expect_error(log("a"), "Non-numeric argument")
Run the code above in your browser using DataLab