tests/testthat/helper-functions.R

skip_if_not_rstudio <- function(version = NULL) {
  available <- rstudioapi::isAvailable(version)
  message <- if (is.null(version)) {
    "RStudio not available"
  } else {
    paste("RStudio version '", version, "' not available", sep = "")
  }

  if (!available) {
    skip(message)
  }

  TRUE
}

Try the whereami package in your browser

Any scripts or data that you put into this service are public.

whereami documentation built on Dec. 28, 2022, 2:40 a.m.