I'm setting up tests for my personal R package and I want to minimise the output to the Build console (I'm on RStudio). I'm using sink
to suppress messages from my own functions (see discussion here) because they're only relevant in an interactive data analysis context. This is not ideal but it works; any hints as to how to handle that better would be appreciated.
What I haven't managed to eliminate are package attachment messages. My package attaches tidyverse
and sf
, which added to testthat
, means I get a long list of well-known mask warnings and version information. Having suppressMessages(library(my_package))
(see the highest voted answer here) on testthat.R
doesn't seem to do the trick either.
Any help would be most appreciated.