tests/testthat/_snaps/detect_mistakes.md

detect_mistakes works with infix operators

Code
  detect_mistakes(quote(TRUE & FALSE), quote(TRUE | FALSE))
Output
  I expected you to call `|` where you called `&`.
Code
  detect_mistakes(quote(2^2), quote(2 * 2))
Output
  I expected you to call `*` where you called `^`.
Code
  detect_mistakes(quote(obj$value), quote(obj@value))
Output
  I expected you to call `@` where you called `$`.
Code
  detect_mistakes(quote(y <- m * x + b), quote(y ~ m * x + b))
Output
  I expected you to call `~` where you called `<-`.
Code
  detect_mistakes(quote(1 - 4), quote(1:4))
Output
  I expected you to call `:` where you called `-`.
Code
  detect_mistakes(quote(a %like% b), quote(a %LIKE% b))
Output
  I expected you to call `%LIKE%` where you called `%like%`.


rstudio-education/grader documentation built on July 6, 2023, 8:48 a.m.