R version 4.3.0 Patched (2023-05-04 r84393) -- "Already Tomorrow"
Copyright (C) 2023 The R Foundation for Statistical Computing
Platform: aarch64-apple-darwin22.4.0 (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 on Unix.
>
> if(.Platform$OS.type == "unix" &&
+ is.null(nsl("cran.r-project.org"))) q()
>
> ## As virtually all http sites redirect to https:, we only test the latter
>
> # test do_download (and "record" #{packages}):
> ap <- available.packages(contrib.url("https://cran.r-project.org"))
> ## IGNORE_RDIFF_BEGIN
> nrow(ap)
[1] 19457
> ## IGNORE_RDIFF_END
>
> # test url connections
> zz <- url("https://cran.r-project.org/")
> readLines(zz)
[1] ""
[2] ""
[3] "