From 91cae35fd1c6fa9e82142bf17d4492f4600516b9 Mon Sep 17 00:00:00 2001 From: Pawel Rucki <12943682+pawelru@users.noreply.github.com> Date: Fri, 1 Dec 2023 17:21:33 +0100 Subject: [PATCH 1/2] avoid pipe and dot; add note blocklist (#797) * avoid pipe and dot; add note blocklist * further standarisation; add skip for missing r2rtf * Fix tt_export --------- Co-authored-by: Emily de la Rua --- .github/workflows/check.yaml | 17 ++++++++++++++--- R/tt_export.R | 2 +- _pkgdown.yml | 7 +++++++ tests/testthat/test-exporters.R | 1 + 4 files changed, 23 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index 8b9625f43..fb51cb290 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -17,9 +17,20 @@ jobs: secrets: REPO_GITHUB_TOKEN: ${{ secrets.REPO_GITHUB_TOKEN }} with: - enable-staged-dependencies-check: false - junit-xml-comparison: false - sd-direction: upstream + additional-env-vars: | + _R_CHECK_CRAN_INCOMING_REMOTE_=false + additional-r-cmd-check-params: --as-cran + enforce-note-blocklist: true + note-blocklist: | + checking dependencies in R code .* NOTE + checking R code for possible problems .* NOTE + checking examples .* NOTE + checking Rd line widths .* NOTE + checking S3 generic/method consistency .* NOTE + checking Rd .usage sections .* NOTE + checking for unstated dependencies in vignettes .* NOTE + unit-test-report-brand: >- + https://raw.githubusercontent.com/insightsengineering/hex-stickers/main/thumbs/rtables.png coverage: if: github.event_name == 'pull_request' name: Coverage 📔 diff --git a/R/tt_export.R b/R/tt_export.R index 932b8bd6e..709c520f4 100644 --- a/R/tt_export.R +++ b/R/tt_export.R @@ -383,7 +383,7 @@ handle_rdf_row <- function(rdfrow, maxlen) { if (is.null(tree_children(clyt))) { return(ret) } else { - ret <- rbind(ret, lapply(tree_children(clyt), .get_formatted_colnames) %>% do.call(cbind, .)) + ret <- rbind(ret, do.call(cbind, lapply(tree_children(clyt), .get_formatted_colnames))) colnames(ret) <- NULL rownames(ret) <- NULL return(ret) diff --git a/_pkgdown.yml b/_pkgdown.yml index 37f8ee873..41db5436e 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -25,6 +25,13 @@ navbar: href: articles/dev-guide/dg_debug_rtables.html - text: Sparse notes on {rtables} internals href: articles/dev-guide/dg_notes.html + reports: + text: Reports + menu: + - text: Coverage report + href: coverage-report/ + - text: Unit test report + href: unit-test-report/ repo: url: diff --git a/tests/testthat/test-exporters.R b/tests/testthat/test-exporters.R index f01f1bf22..ec10f6793 100644 --- a/tests/testthat/test-exporters.R +++ b/tests/testthat/test-exporters.R @@ -296,6 +296,7 @@ test_that("path_enriched_df works for tables with a column that has all length 1 }) test_that("export_as_rtf works", { + testthat::skip_if_not_installed("r2rtf") tbl <- tt_to_export() tmpf <- tempfile(fileext = ".rtf") From 0c39cc7f36a1286f55b2bb83b9b0a80f12efe946 Mon Sep 17 00:00:00 2001 From: pawelru Date: Fri, 1 Dec 2023 16:22:41 +0000 Subject: [PATCH 2/2] [skip actions] Bump version to 0.6.5.9020 --- DESCRIPTION | 4 ++-- NEWS.md | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index a47e89d08..78b53b71a 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: rtables Title: Reporting Tables -Version: 0.6.5.9019 -Date: 2023-11-29 +Version: 0.6.5.9020 +Date: 2023-12-01 Authors@R: c( person("Gabriel", "Becker", , "gabembecker@gmail.com", role = "aut", comment = "Original creator of the package"), diff --git a/NEWS.md b/NEWS.md index 4f99a09a1..6f4c6e4d9 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,4 +1,4 @@ -## rtables 0.6.5.9019 +## rtables 0.6.5.9020 ### New Features * Removed `ref_group` reordering in column splits so not to change the order. * Added `bold` argument to `as_html` to bold specified elements, and `header_sep_line`