Debugging tests

I am trying to write some tests

In the test I first make my call to a client side function which should return a value, so my test can check that value:

test_that("simple synthetic test", {
    res <- ds.syn2(data="D", method = "cart", m = 1, seed = 123)

But the call is failing and I get the familiar “check datashield.errors()”. But how can I do that in the context of the testing framework? Tom


The “argument tests” have examples of checking “datashield.errors()”, for example,

Note the use of “expect_error” around the call to the method.


ah the “expect_error” is the magic I was looking for!