Nothing
library("vcr")
invisible(vcr::vcr_configure(
dir = "../fixtures",
filter_sensitive_data = list(
"<<ebird_api_key>>" = Sys.getenv("EBIRD_KEY")
),
json_pretty = TRUE
))
sw <- suppressWarnings
has_internet <- function() {
requireNamespace("crul")
crul::ok("https://search.idigbio.org/v2/search/records")
}
has_idigbio <- function() {
z <- try(sw(readLines("https://www.google.com", n = 1)),
silent = TRUE)
!inherits(z, "try-error")
}
skip_if_ <- function(fun) {
function() {
if (eval(fun)()) return()
testthat::skip("no internet")
}
}
skip_if_net_down <- skip_if_(has_internet)
skip_if_idigbio_down <- skip_if_(has_idigbio)
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.