title: Throw warnings rather than errors in testthat
body: <p>I'm writing unit tests for a package and there are some tests where I don't want the tests to throw errors if they fail but to instead give warnings.</p>
  <p>This isn't my real code, but let's say I want to test something like:</p>
  <pre class="lang-r prettyprint-override"><code>add_x_y &lt;- function(x, y) x + y
  expect_equal( add_x_y(2, 2), 3 )
  </code></pre>
  <p>The output is an error:</p>
  <pre class="lang-r prettyprint-override"><code>Error: add_x_y(2, 2) not equal to 3.
  1/1 mismatches
  [1] 4 - 3 == 1
  </code></pre>
  <p>Is there a variant or alternative function that would throw a warning rather than an error for this check?</p>