R Under development (unstable) (2021-06-17 r80510) -- "Unsuffered Consequences"
Copyright (C) 2021 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> ## These are tests that require a working Internet connection.
> ## We attempt to test for that.
>
> if(.Platform$OS.type == "unix" &&
+ is.null(nsl("cran.r-project.org"))) q()
>
> # test do_download (and "record" #{packages}):
> ap <- available.packages(contrib.url("http://cran.r-project.org"))
> ## IGNORE_RDIFF_BEGIN
> nrow(ap)
[1] 17721
> ## IGNORE_RDIFF_END
>
> # test url connections on http
> zz <- url("http://cran.r-project.org/")
> readLines(zz)
[1] ""
[2] ""
[3] "