~/talk

{shinytest2}: Unit testing for Shiny applications

Talkat rstudio::conf(2022) · 2022-07-25..07-28· [testing]
slides:none on file

shinytest2 provides regression testing for Shiny apps by driving a headless Chrome via chromote and integrating with testthat; recorded interactions (using record_test / AppDriver) become runnable tests that execute in seconds and replay a 10‑second manual session. Prior shinytest (PhantomJS) enters maintenance mode so existing screenshots break; shinytest2 lets you open a live Chrome view and use DevTools to debug failing runs. Advice: export reactive values, avoid brittle screenshot assertions, prefer explicit expectations.

AI-written summary · about

  1. 0:00Introduction to app testing
  2. 1:10The challenges of manual testing
  3. 2:59Introduction to testthat
  4. 6:12Overview of shinytest2
  5. 8:33Building a shinytest2 example
  6. 11:02Recording tests effectively
  7. 12:55Debugging with live views
  8. 14:35Best practices and conclusion
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.