I’m creating a R package that uses internet inside a function.
I create a test (using testthat) that is “Internet connection is available”. But I would like to create another one that is “Internet connection is NOT available”.
I think I need to mock the function, but I have no experience with it.
Repo: GitHub - brunomioto/feowR: Download shapefiles of Freshwater Ecoregions of the World (FEOW)
Function: feowR/R/read_feow.R at 90d821907e837e2618367eefb4b8e6d03c0ccb83 · brunomioto/feowR · GitHub