From ef26d3a616a83a2f1a02584747976ddefbf23ed6 Mon Sep 17 00:00:00 2001 From: Jan Philipp Dietrich Date: Tue, 2 May 2023 12:33:55 +0200 Subject: [PATCH] fixed tests updated cran comments --- cran-comments.md | 29 ++++++++++++++++++++++++++--- tests/testthat/test-caching.R | 6 +++--- 2 files changed, 29 insertions(+), 6 deletions(-) diff --git a/cran-comments.md b/cran-comments.md index e4b8e849..e29fb795 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,4 +1,27 @@ ## CHANGES -* fixed issue with tar gzip compression on Solaris systems -* fixed rare sorting issue on MACOS system (different file order compared to other systems) -* fixed rounding issue in tests on ATLAS system +* fixed a test issue incorrectly detecting two paths as different under Windows (due to different lower/upper cases in the returned paths) +* changed default cachetype from "rev" to "def" (shared cache folder instead of separate cache folders) +* added limited caching support for terra objects + +## Test environments +* local R installation, R 4.1.2 +* rhub Ubuntu Linux 20.04.1 LTS, R-release, GCC +* rhub Windows Server 2022, R-devel, 64 bit +* rhub Fedora Linux, R-devel, clang, gfortran + +## R CMD check results + +Rhub Windows devel: +* checking for non-standard things in the check directory ... NOTE + Found the following files/directories: + ''NULL'' +* checking for detritus in the temp directory ... NOTE +Found the following files/directories: + 'lastMiKTeXException' + +Rhub Fedora and Ubuntu Linux: + +* checking HTML version of manual ... NOTE +Skipping checking HTML validation: no command 'tidy' found + +To my understanding the issue on Rhub Windows devel seems to be a problem with the local MikTex installation on the server as it does not occur on other test machines and as I could not reproduce the problem myself. In addition, there are no direct calls to miktex so that the temporary directory seems to be created by some other tools. Similarly, the issue on Linux seems to be a problem of the test machines unrelated to the package. diff --git a/tests/testthat/test-caching.R b/tests/testthat/test-caching.R index 370a3a71..96352e6f 100644 --- a/tests/testthat/test-caching.R +++ b/tests/testthat/test-caching.R @@ -119,7 +119,7 @@ test_that("terra objects can be cached", { expect_message(a <- readSource("SingleSource"), "writing cache") expect_message(b <- readSource("SingleSource"), "loading cache") # converting to data frame because terra::sources is different - expect_identical(terra::as.data.frame(a, xy = TRUE), + expect_equal(terra::as.data.frame(a, xy = TRUE), terra::as.data.frame(b, xy = TRUE)) expect_identical(names(a), names(b)) @@ -137,7 +137,7 @@ test_that("terra objects can be cached", { expect_message(a <- readSource("InMemory"), "writing cache") expect_message(b <- readSource("InMemory"), "loading cache") # converting to data frame because terra::sources is different - expect_identical(terra::as.data.frame(a, xy = TRUE), + expect_equal(terra::as.data.frame(a, xy = TRUE), terra::as.data.frame(b, xy = TRUE)) expect_identical(names(a), names(b)) @@ -155,7 +155,7 @@ test_that("terra objects can be cached", { expect_message(a <- readSource("MultiSource"), "writing cache") expect_message(b <- readSource("MultiSource"), "loading cache") # converting to data frame because terra::sources is different - expect_identical(terra::as.data.frame(a, xy = TRUE), + expect_equal(terra::as.data.frame(a, xy = TRUE), terra::as.data.frame(b, xy = TRUE)) expect_identical(names(a), names(b))