Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

small fix and linting in tests #232

Merged
merged 1 commit into from
Dec 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .buildlibrary
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ValidationKey: '63330315'
ValidationKey: '63359856'
AcceptedWarnings:
- 'Warning: package ''.*'' was built under R version'
- 'Warning: namespace ''.*'' is not available and has been replaced'
Expand Down
4 changes: 2 additions & 2 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ cff-version: 1.2.0
message: If you use this software, please cite it using the metadata from this file.
type: software
title: 'madrat: May All Data be Reproducible and Transparent (MADRaT) *'
version: 3.15.5
date-released: '2024-12-16'
version: 3.15.6
date-released: '2024-12-19'
abstract: Provides a framework which should improve reproducibility and transparency
in data processing. It provides functionality such as automatic meta data creation
and management, rudimentary quality management, data caching, work-flow management
Expand Down
6 changes: 3 additions & 3 deletions CRAN-SUBMISSION
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
Version: 3.6.4
Date: 2023-08-23 08:10:10 UTC
SHA: d549de159878c4be432d706e3d676ab67de4c98b
Version: 3.15.5
Date: 2024-12-16 18:59:12 UTC
SHA: f1b12e5c84e475ea3af3cbbedf1ed3cb9a616c12
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Type: Package
Package: madrat
Title: May All Data be Reproducible and Transparent (MADRaT) *
Version: 3.15.5
Date: 2024-12-16
Version: 3.15.6
Date: 2024-12-19
Authors@R: c(
person("Jan Philipp", "Dietrich", , "[email protected]", role = c("aut", "cre"),
comment = c(affiliation = "Potsdam Institute for Climate Impact Research", ORCID = "0000-0002-4309-6431")),
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# May All Data be Reproducible and Transparent (MADRaT) *

R package **madrat**, version **3.15.5**
R package **madrat**, version **3.15.6**

[![CRAN status](https://www.r-pkg.org/badges/version/madrat)](https://cran.r-project.org/package=madrat) [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.1115490.svg)](https://doi.org/10.5281/zenodo.1115490) [![R build status](https://github.com/pik-piam/madrat/workflows/check/badge.svg)](https://github.com/pik-piam/madrat/actions) [![codecov](https://codecov.io/gh/pik-piam/madrat/branch/master/graph/badge.svg)](https://app.codecov.io/gh/pik-piam/madrat) [![r-universe](https://pik-piam.r-universe.dev/badges/madrat)](https://pik-piam.r-universe.dev/builds)

Expand Down Expand Up @@ -55,7 +55,7 @@ In case of questions / problems please contact Jan Philipp Dietrich <dietrich@pi

To cite package **madrat** in publications use:

Dietrich J, Baumstark L, Wirth S, Giannousakis A, Rodrigues R, Bodirsky B, Leip D, Kreidenweis U, Klein D, Sauer P (2024). "madrat: May All Data be Reproducible and Transparent (MADRaT) *." doi:10.5281/zenodo.1115490 <https://doi.org/10.5281/zenodo.1115490>, Version: 3.15.5, <https://github.com/pik-piam/madrat>.
Dietrich J, Baumstark L, Wirth S, Giannousakis A, Rodrigues R, Bodirsky B, Leip D, Kreidenweis U, Klein D, Sauer P (2024). "madrat: May All Data be Reproducible and Transparent (MADRaT) *." doi:10.5281/zenodo.1115490 <https://doi.org/10.5281/zenodo.1115490>, Version: 3.15.6, <https://github.com/pik-piam/madrat>.

A BibTeX entry for LaTeX users is

Expand All @@ -64,9 +64,9 @@ A BibTeX entry for LaTeX users is
title = {madrat: May All Data be Reproducible and Transparent (MADRaT) *},
author = {Jan Philipp Dietrich and Lavinia Baumstark and Stephen Wirth and Anastasis Giannousakis and Renato Rodrigues and Benjamin Leon Bodirsky and Debbora Leip and Ulrich Kreidenweis and David Klein and Pascal Sauer},
doi = {10.5281/zenodo.1115490},
date = {2024-12-16},
date = {2024-12-19},
year = {2024},
url = {https://github.com/pik-piam/madrat},
note = {Version: 3.15.5},
note = {Version: 3.15.6},
}
```
14 changes: 11 additions & 3 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
## NOTES

The R precheck complains that "Author field differs from that derived from Authors@R". We checked
it and the behavior is ok. It is just that the naming of affiliation and ORCID leads to slightly
different formatting when returned, but the information stays the same.

## CHANGES
* fixed numeric_version-related error currently showing up on r-devel machines on CRAN
* fixed pre-test error also related to numeric_version
* fixed CRAN precheck error related to an error detection on a german system

* fixed recently popped up testthat errors caused by stricter behavior of recent testthat versions
* pushed version to most recent release

## Test environments
* local R installation, R 4.1.2
* rhub::check_for_cran()
* rhub checks
11 changes: 5 additions & 6 deletions tests/testthat/test-redirectSource.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
test_that("redirectSource writes to config as intended", {
withr::local_dir(withr::local_tempdir())

expect_error(redirectSource("foo", target = "foo2"), "No such file or directory|cannot find the file")
expect_error(redirectSource("foo", target = "foo2"),
"No such file or directory|cannot find the file|Datei nicht finden")
dir.create("foo2")
dir.create("foo3")
dir.create("example2")
Expand Down Expand Up @@ -70,11 +71,9 @@ test_that("redirectSource symlinks other files", {
redirectSource("Example", target = target)
expect_identical(as.vector(readSource("Example")), 456789)
redirectSource("Example", target = target, linkOthers = FALSE)
expect_error({
expect_warning({
readSource("Example")
}, "cannot open file 'Example2.txt': No such file or directory", fixed = TRUE)
}, "cannot open the connection")
expect_error(expect_warning(readSource("Example"),
"cannot open file 'Example2.txt': No such file or directory",
fixed = TRUE), "cannot open the connection")
})

test_that("scope for redirectSource can be set", {
Expand Down
Loading