diff --git a/.Rbuildignore b/.Rbuildignore index 46a37fe..9ca7d6c 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -17,3 +17,4 @@ myignore ^ggeasy\.Rproj$ ^CRAN-RELEASE$ ^\.github$ +^tests/README\.md$ diff --git a/.github/.gitignore b/.github/.gitignore new file mode 100644 index 0000000..2d19fc7 --- /dev/null +++ b/.github/.gitignore @@ -0,0 +1 @@ +*.html diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml new file mode 100644 index 0000000..310cb2c --- /dev/null +++ b/.github/workflows/R-CMD-check.yaml @@ -0,0 +1,106 @@ +# NOTE: This workflow is overkill for most R packages +# check-standard.yaml is likely a better choice +# usethis::use_github_action("check-standard") will install it. +# +# For help debugging build failures open an issue on the RStudio community with the 'github-actions' tag. +# https://community.rstudio.com/new-topic?category=Package%20development&tags=github-actions +on: + push: + branches: + - main + - master + pull_request: + branches: + - main + - master + +name: R-CMD-check + +jobs: + R-CMD-check: + runs-on: ${{ matrix.config.os }} + + name: ${{ matrix.config.os }} (${{ matrix.config.r }}) + + strategy: + fail-fast: false + matrix: + config: + - {os: macOS-latest, r: 'release'} + - {os: windows-latest, r: 'release'} + - {os: windows-latest, r: '3.6'} + - {os: ubuntu-16.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"} + - {os: ubuntu-16.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"} + - {os: ubuntu-16.04, r: 'oldrel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"} + - {os: ubuntu-16.04, r: '3.5', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"} + - {os: ubuntu-16.04, r: '3.4', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"} + - {os: ubuntu-16.04, r: '3.3', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"} + + env: + R_REMOTES_NO_ERRORS_FROM_WARNINGS: true + RSPM: ${{ matrix.config.rspm }} + GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + + steps: + - uses: actions/checkout@v2 + + - uses: r-lib/actions/setup-r@v1 + with: + r-version: ${{ matrix.config.r }} + http-user-agent: ${{ matrix.config.http-user-agent }} + + - uses: r-lib/actions/setup-pandoc@v1 + + - name: Query dependencies + run: | + install.packages('remotes') + saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2) + writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version") + shell: Rscript {0} + + - name: Cache R packages + if: runner.os != 'Windows' + uses: actions/cache@v2 + with: + path: ${{ env.R_LIBS_USER }} + key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }} + restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1- + + - name: Install system dependencies + if: runner.os == 'Linux' + run: | + while read -r cmd + do + eval sudo $cmd + done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "16.04"))') + + - name: Install dependencies + run: | + remotes::install_deps(dependencies = TRUE) + remotes::install_cran("rcmdcheck") + shell: Rscript {0} + + - name: Session info + run: | + options(width = 100) + pkgs <- installed.packages()[, "Package"] + sessioninfo::session_info(pkgs, include_base = TRUE) + shell: Rscript {0} + + - name: Check + env: + _R_CHECK_CRAN_INCOMING_: false + run: rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check") + shell: Rscript {0} + + - name: Show testthat output + if: always() + run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true + shell: bash + + - name: Upload check results + if: failure() + uses: actions/upload-artifact@main + with: + name: ${{ runner.os }}-r${{ matrix.config.r }}-results + path: check diff --git a/.travis.yml b/.travis.yml index 9e86c63..232d1a3 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,13 @@ language: R cache: packages -r_github_packages: -- metrumresearchgroup/covrpage +apt_packages: + - libharfbuzz-dev + - libfribidi-dev + - libgit2-dev + +r_github_packages: +- metrumresearchgroup/covrpage - r-lib/pkgdown after_success: diff --git a/DESCRIPTION b/DESCRIPTION index 07118f3..1773df0 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: ggeasy Title: Easy Access to 'ggplot2' Commands -Version: 0.1.2 +Version: 0.1.3 Authors@R: c( person("Jonathan", "Carroll", email = "rpkg@jcarroll.com.au", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-1404-5264")), person("Alicia", "Schep", email = "aschep@gmail.com", role = c("aut"), comment = c(ORCID = "0000-0002-3915-0618")), @@ -18,7 +18,7 @@ LazyData: true Imports: ggplot2, rlang -RoxygenNote: 7.0.2 +RoxygenNote: 7.1.1 Suggests: knitr, rmarkdown, diff --git a/NEWS.md b/NEWS.md index 6c31ca0..002618c 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,9 @@ +# ggeasy 0.1.3 + +* Tests updated to comply with new r-devel all.equal() environment checks +* Added easy_center_title() (#44, @thomas-neitmann) +* New logo (#57, @statnmap) + # ggeasy 0.1.2 * Support for ggplot2 3.3.0 (no implementation change required) diff --git a/README.Rmd b/README.Rmd index 903cd1b..27d52f8 100644 --- a/README.Rmd +++ b/README.Rmd @@ -16,9 +16,10 @@ knitr::opts_chunk$set( # ggeasy -[![Covrpage Summary](https://img.shields.io/badge/covrpage-Last_Build_2020_03_07-yellowgreen.svg)](https://github.com/jonocarroll/ggeasy/blob/master/tests/README.md) +[![Covrpage Summary](https://img.shields.io/badge/covrpage-Last_Build_2021_01_06-yellowgreen.svg)](https://github.com/jonocarroll/ggeasy/blob/master/tests/README.md) [![Travis build status](https://travis-ci.org/jonocarroll/ggeasy.svg?branch=master)](https://travis-ci.org/jonocarroll/ggeasy) [![AppVeyor build status](https://ci.appveyor.com/api/projects/status/github/jonocarroll/ggeasy?branch=master&svg=true)](https://ci.appveyor.com/project/jonocarroll/ggeasy) +[![R-CMD-check](https://github.com/jonocarroll/ggeasy/workflows/R-CMD-check/badge.svg)](https://github.com/jonocarroll/ggeasy/actions) [![Codecov test coverage](https://codecov.io/gh/jonocarroll/ggeasy/branch/master/graph/badge.svg)](https://codecov.io/gh/jonocarroll/ggeasy?branch=master) [![CRAN status](https://www.r-pkg.org/badges/version/ggeasy)](https://CRAN.R-project.org/package=ggeasy) diff --git a/README.md b/README.md index 4470d09..a2b8b67 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,17 @@ -ggeasy -====================================================================== +# ggeasy [![Covrpage -Summary](https://img.shields.io/badge/covrpage-Last_Build_2020_03_07-yellowgreen.svg)](https://github.com/jonocarroll/ggeasy/blob/master/tests/README.md) +Summary](https://img.shields.io/badge/covrpage-Last_Build_2021_01_06-yellowgreen.svg)](https://github.com/jonocarroll/ggeasy/blob/master/tests/README.md) [![Travis build status](https://travis-ci.org/jonocarroll/ggeasy.svg?branch=master)](https://travis-ci.org/jonocarroll/ggeasy) [![AppVeyor build status](https://ci.appveyor.com/api/projects/status/github/jonocarroll/ggeasy?branch=master&svg=true)](https://ci.appveyor.com/project/jonocarroll/ggeasy) +[![R-CMD-check](https://github.com/jonocarroll/ggeasy/workflows/R-CMD-check/badge.svg)](https://github.com/jonocarroll/ggeasy/actions) [![Codecov test coverage](https://codecov.io/gh/jonocarroll/ggeasy/branch/master/graph/badge.svg)](https://codecov.io/gh/jonocarroll/ggeasy?branch=master) [![CRAN @@ -28,20 +28,22 @@ Now, can you please rotate the `x` axis labels to vertical? `ggeasy` is here to make that a little easier. -Installation ------------- +## Installation You can install the latest released version of `ggeasy` from CRAN with: - install.packages("ggeasy") +``` r +install.packages("ggeasy") +``` or the bleeding-edge development version from GitHub with - # install.packages("remotes") - remotes::install_github("jonocarroll/ggeasy") +``` r +# install.packages("remotes") +remotes::install_github("jonocarroll/ggeasy") +``` -Reference ---------- +## Reference See the [`pkgdown` site](https://jonocarroll.github.io/ggeasy/). @@ -52,128 +54,141 @@ walkthrough using `ggeasy` which covers some of the major features: [![Watch the video](https://img.youtube.com/vi/iAH1GJoBZmI/maxresdefault.jpg)](https://youtu.be/iAH1GJoBZmI) -Examples --------- +## Examples - library(ggplot2) - library(ggeasy) +``` r +library(ggplot2) +library(ggeasy) - # rotate x axis labels - ggplot(mtcars, aes(hp, mpg)) + - geom_point() + - easy_rotate_x_labels() +# rotate x axis labels +ggplot(mtcars, aes(hp, mpg)) + + geom_point() + + easy_rotate_x_labels() +``` ![](man/figures/example-1.png) - - # rotate y axis labels - ggplot(mtcars, aes(hp, mpg)) + - geom_point() + - easy_rotate_y_labels() +``` r +# rotate y axis labels +ggplot(mtcars, aes(hp, mpg)) + + geom_point() + + easy_rotate_y_labels() +``` ![](man/figures/example-2.png) - - # remove 'size' legend - ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + - geom_point() + - easy_remove_legend(size) +``` r +# remove 'size' legend +ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + + geom_point() + + easy_remove_legend(size) +``` ![](man/figures/example-3.png) - - # make the x axis labels larger - ggplot(mtcars, aes(mpg, hp)) + - geom_point() + - easy_x_axis_labels_size(22) +``` r +# make the x axis labels larger +ggplot(mtcars, aes(mpg, hp)) + + geom_point() + + easy_x_axis_labels_size(22) +``` ![](man/figures/example-4.png) - - # make all the text red - ggplot(mtcars, aes(mpg, hp)) + - geom_point(aes(fill = gear)) + - easy_all_text_color("red") +``` r +# make all the text red +ggplot(mtcars, aes(mpg, hp)) + + geom_point(aes(fill = gear)) + + easy_all_text_color("red") +``` ![](man/figures/example-5.png) - - # remove just x axis - ggplot(mtcars, aes(wt, mpg)) + - geom_point() + - easy_remove_x_axis() +``` r +# remove just x axis +ggplot(mtcars, aes(wt, mpg)) + + geom_point() + + easy_remove_x_axis() +``` ![](man/figures/example-6.png) - - # remove y axis ticks - ggplot(mtcars, aes(wt, mpg)) + - geom_point() + - easy_remove_y_axis(what = "ticks") +``` r +# remove y axis ticks +ggplot(mtcars, aes(wt, mpg)) + + geom_point() + + easy_remove_y_axis(what = "ticks") +``` ![](man/figures/example-7.png) - - # move legends to bottom - ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + - geom_point() + - easy_move_legend("bottom") +``` r +# move legends to bottom +ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + + geom_point() + + easy_move_legend("bottom") +``` ![](man/figures/example-8.png) - - # move legend to left side - ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + - geom_point() + - easy_legend_at("left") +``` r +# move legend to left side +ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + + geom_point() + + easy_legend_at("left") +``` ![](man/figures/example-9.png) - - # Make legends horizontal - ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + - geom_point() + easy_rotate_legend("horizontal") +``` r +# Make legends horizontal +ggplot(mtcars, aes(wt, mpg, colour = cyl, size = hp)) + + geom_point() + easy_rotate_legend("horizontal") +``` ![](man/figures/example-10.png) - - # use labelled variables - iris_labs <- iris - labelled::var_label(iris_labs$Species) <- "Flower\nSpecies" - labelled::var_label(iris_labs$Sepal.Length) <- "Length of Sepal" - iris_labs_2 <- iris_labs - labelled::var_label(iris_labs_2$Species) <- "Sub-genera" - - # use variable labels automatically - ggplot(iris_labs, aes(x = Sepal.Length, y = Sepal.Width)) + - geom_line(aes(colour = Species)) + - geom_point(data = iris_labs_2, aes(fill = Species), shape = 24) + - easy_labs() +``` r +# use labelled variables +iris_labs <- iris +labelled::var_label(iris_labs$Species) <- "Flower\nSpecies" +labelled::var_label(iris_labs$Sepal.Length) <- "Length of Sepal" +iris_labs_2 <- iris_labs +labelled::var_label(iris_labs_2$Species) <- "Sub-genera" + +# use variable labels automatically +ggplot(iris_labs, aes(x = Sepal.Length, y = Sepal.Width)) + + geom_line(aes(colour = Species)) + + geom_point(data = iris_labs_2, aes(fill = Species), shape = 24) + + easy_labs() +``` ![](man/figures/example-11.png) These functions will try to teach you the โ€˜officialโ€™ way to achieve these goal, usually via the `teach` argument (where implemented) - ggplot(mtcars, aes(hp, mpg)) + - geom_point() + - easy_rotate_y_labels(angle = "startatbottom", teach = TRUE) - #> easy_rotate_y_labels call can be substituted with: - #> theme(axis.text.y = element_text(angle = 90, hjust = 0)) +``` r +ggplot(mtcars, aes(hp, mpg)) + + geom_point() + + easy_rotate_y_labels(angle = "startatbottom", teach = TRUE) +#> easy_rotate_y_labels call can be substituted with: +#> theme(axis.text.y = element_text(angle = 90, hjust = 0)) +``` ![](man/figures/teach-1.png) - - ggplot(mtcars, aes(wt, mpg)) + - geom_point() + - easy_remove_y_axis(what = "ticks", teach = TRUE) - #> easy_remove_y_axis call can be substituted with: - #> theme(axis.ticks.y = element_blank()) +``` r +ggplot(mtcars, aes(wt, mpg)) + + geom_point() + + easy_remove_y_axis(what = "ticks", teach = TRUE) +#> easy_remove_y_axis call can be substituted with: +#> theme(axis.ticks.y = element_blank()) +``` ![](man/figures/teach-2.png) -Credits -------- +## Credits Many thanks to [Sรฉbastien Rochette (@statnmap)](https://statnmap.com/) for the design and execution of the hex logo. diff --git a/cran-comments.md b/cran-comments.md index dedcf77..a23b088 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,13 +1,25 @@ ## Updated package -Correction to address failing tests. - -No code change required - output of test changed. Updated for compatibility. +Correction to address failing tests and comply with new r-devel all.equal() ## R CMD check results 0 errors | 0 warnings | 0 notes +Checked locally on r-devel 2021-01-01 r79748. + +rhub::check_for_cran(): + +Windows Server 2008 R2 SP1, R-devel, 32/64 bit :: OK +Ubuntu Linux 16.04 LTS, R-release, GCC :: OK +Fedora Linux, R-devel, clang, gfortran :: OK + +Win-builder: + +release :: OK +old_release :: OK +devel :: OK + ## Reverse dependencies None. diff --git a/tests/README.md b/tests/README.md index eb956d8..2236ab7 100644 --- a/tests/README.md +++ b/tests/README.md @@ -1,9 +1,12 @@ Tests and Coverage ================ -07 March, 2020 10:37:14 +06 January, 2021 22:36:25 + +- [Coverage](#coverage) +- [Unit Tests](#unit-tests) This output is created by -[covrpage](https://github.com/metrumresearchgroup/covrpage). +[covrpage](https://github.com/yonicd/covrpage). ## Coverage @@ -11,8 +14,8 @@ Coverage summary is created using the [covr](https://github.com/r-lib/covr) package. | Object | Coverage (%) | -| :-------------------------- | :----------: | -| ggeasy | 96.52 | +|:----------------------------|:------------:| +| ggeasy | 96.53 | | [R/legend.R](../R/legend.R) | 90.54 | | [R/axis.R](../R/axis.R) | 100.00 | | [R/labs.R](../R/labs.R) | 100.00 | @@ -24,94 +27,93 @@ Coverage summary is created using the ## Unit Tests Unit Test summary is created using the -[testthat](https://github.com/r-lib/testthat) -package. +[testthat](https://github.com/r-lib/testthat) package. | file | n | time | error | failed | skipped | warning | icon | -| :------------------------------------------------ | --: | ----: | ----: | -----: | ------: | ------: | :--- | -| [test-labs.R](testthat/test-labs.R) | 10 | 1.490 | 0 | 0 | 4 | 0 | ๐Ÿ”ถ | -| [test-legend.R](testthat/test-legend.R) | 87 | 0.636 | 0 | 0 | 0 | 0 | | -| [test-remove-axis.R](testthat/test-remove-axis.R) | 20 | 0.224 | 0 | 0 | 0 | 0 | | -| [test-rotate.R](testthat/test-rotate.R) | 23 | 0.192 | 0 | 0 | 0 | 0 | | -| [test-text.R](testthat/test-text.R) | 301 | 0.325 | 0 | 0 | 0 | 0 | | +|:--------------------------------------------------|----:|------:|------:|-------:|--------:|--------:|:-----| +| [test-labs.R](testthat/test-labs.R) | 10 | 1.896 | 0 | 0 | 4 | 0 | ๐Ÿ”ถ | +| [test-legend.R](testthat/test-legend.R) | 87 | 1.029 | 0 | 0 | 0 | 0 | | +| [test-remove-axis.R](testthat/test-remove-axis.R) | 20 | 0.349 | 0 | 0 | 0 | 0 | | +| [test-rotate.R](testthat/test-rotate.R) | 23 | 0.289 | 0 | 0 | 0 | 0 | | +| [test-text.R](testthat/test-text.R) | 302 | 0.562 | 0 | 0 | 0 | 0 | |
- - Show Detailed Test Results + +Show Detailed Test Results | file | context | test | status | n | time | icon | -| :----------------------------------------------------- | :------------------- | :-------------------------------------------------------------- | :------ | --: | ----: | :--- | -| [test-labs.R](testthat/test-labs.R#L22) | attr labs | easy\_labs uses column attrib | SKIPPED | 4 | 0.556 | ๐Ÿ”ถ | -| [test-labs.R](testthat/test-labs.R#L39_L40) | attr labs | regular labs overides easy\_labs | SKIPPED | 2 | 0.286 | ๐Ÿ”ถ | -| [test-labs.R](testthat/test-labs.R#L50_L51) | attr labs | regular labs pass new labels through easy\_labs | SKIPPED | 2 | 0.258 | ๐Ÿ”ถ | -| [test-labs.R](testthat/test-labs.R#L69_L70) | attr labs | column name used when no column attrib present | SKIPPED | 2 | 0.390 | ๐Ÿ”ถ | -| [test-legend.R](testthat/test-legend.R#L8) | remove legend | easy\_remove\_legend works with no argument | PASS | 1 | 0.014 | | -| [test-legend.R](testthat/test-legend.R#L14) | remove legend | easy\_remove\_legend works with single character argument | PASS | 1 | 0.014 | | -| [test-legend.R](testthat/test-legend.R#L20) | remove legend | easy\_remove\_legend works with single bare argument | PASS | 1 | 0.015 | | -| [test-legend.R](testthat/test-legend.R#L26) | remove legend | easy\_remove\_legend works with multiple character arguments | PASS | 1 | 0.022 | | -| [test-legend.R](testthat/test-legend.R#L32) | remove legend | easy\_remove\_legend works with multiple bare arguments | PASS | 1 | 0.013 | | -| [test-legend.R](testthat/test-legend.R#L39) | remove legend | easy\_remove\_legend teach = TRUE works with no other arguments | PASS | 2 | 0.005 | | -| [test-legend.R](testthat/test-legend.R#L47) | remove legend | easy\_remove\_legend teach = TRUE works with specific aes | PASS | 2 | 0.005 | | -| [test-legend.R](testthat/test-legend.R#L55) | remove legend | easy\_remove\_legend teach = TRUE works with multiple aes | PASS | 2 | 0.004 | | -| [test-legend.R](testthat/test-legend.R#L62) | move legend | easy\_change\_legend errors with no argument | PASS | 1 | 0.012 | | -| [test-legend.R](testthat/test-legend.R#L68) | move legend | easy\_change\_legend works with combinations | PASS | 4 | 0.053 | | -| [test-legend.R](testthat/test-legend.R#L83) | move legend | easy\_move\_legend works with no argument | PASS | 1 | 0.012 | | -| [test-legend.R](testthat/test-legend.R#L89) | move legend | easy\_move\_legend works with specified argument | PASS | 3 | 0.045 | | -| [test-legend.R](testthat/test-legend.R#L99) | move legend | easy\_move\_legend errors with bad argument | PASS | 1 | 0.007 | | -| [test-legend.R](testthat/test-legend.R#L105) | move legend | easy\_move\_legend aliases work | PASS | 3 | 0.040 | | -| [test-legend.R](testthat/test-legend.R#L117) | move legend | easy\_move\_legend teach = TRUE works with combinations | PASS | 4 | 0.023 | | -| [test-legend.R](testthat/test-legend.R#L126) | move legend | easy\_legend\_at teach = TRUE works with combinations | PASS | 4 | 0.020 | | -| [test-legend.R](testthat/test-legend.R#L135) | move legend | easy\_change\_legend teach = TRUE works with position | PASS | 3 | 0.016 | | -| [test-legend.R](testthat/test-legend.R#L145) | legend direction | easy\_rotate\_legend works with no argument | PASS | 1 | 0.014 | | -| [test-legend.R](testthat/test-legend.R#L151) | legend direction | easy\_rotate\_legend works with combinations | PASS | 4 | 0.059 | | -| [test-legend.R](testthat/test-legend.R#L166) | legend direction | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.018 | | -| [test-legend.R](testthat/test-legend.R#L177) | legend justification | easy\_adjust\_legend works with no argument | PASS | 1 | 0.015 | | -| [test-legend.R](testthat/test-legend.R#L183) | legend justification | easy\_adjust\_legend works with combinations | PASS | 3 | 0.046 | | -| [test-legend.R](testthat/test-legend.R#L193) | legend justification | easy\_adjust\_legend errors with bad argument | PASS | 1 | 0.006 | | -| [test-legend.R](testthat/test-legend.R#L199) | legend justification | easy\_adjust\_legend teach = TRUE works with justification | PASS | 3 | 0.020 | | -| [test-legend.R](testthat/test-legend.R#L207) | legend justification | easy\_change\_legend teach = TRUE works with justification | PASS | 3 | 0.026 | | -| [test-legend.R](testthat/test-legend.R#L215) | legend justification | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.021 | | -| [test-legend.R](testthat/test-legend.R#L224) | legend title | easy\_add\_legend\_title errors with no argument | PASS | 1 | 0.006 | | -| [test-legend.R](testthat/test-legend.R#L230) | legend title | easy\_add\_legend\_title relabels a single legend title | PASS | 1 | 0.011 | | -| [test-legend.R](testthat/test-legend.R#L237) | legend title | easy\_add\_legend\_title relabels all legend titles | PASS | 9 | 0.020 | | -| [test-legend.R](testthat/test-legend.R#L245) | legend title | easy\_add\_legend\_title teach = TRUE works with specific aes | PASS | 4 | 0.019 | | -| [test-legend.R](testthat/test-legend.R#L254) | legend title | easy\_add\_legend\_title teach = TRUE works with unspecific aes | PASS | 12 | 0.023 | | -| [test-legend.R](testthat/test-legend.R#L268) | legend title | easy\_remove\_legend\_title works | PASS | 1 | 0.012 | | -| [test-remove-axis.R](testthat/test-remove-axis.R#L13) | remove axes | no argument | PASS | 3 | 0.044 | | -| [test-remove-axis.R](testthat/test-remove-axis.R#L44) | remove axes | explicit axis | PASS | 10 | 0.107 | | -| [test-remove-axis.R](testthat/test-remove-axis.R#L88) | remove axes | multiple components | PASS | 4 | 0.061 | | -| [test-remove-axis.R](testthat/test-remove-axis.R#L107) | remove axes | teach argument produces working code | PASS | 3 | 0.012 | | -| [test-rotate.R](testthat/test-rotate.R#L8) | rotate labels | rotation of both labels | PASS | 17 | 0.119 | | -| [test-rotate.R](testthat/test-rotate.R#L62) | rotate labels | rotation of x labels | PASS | 3 | 0.039 | | -| [test-rotate.R](testthat/test-rotate.R#L77) | rotate labels | rotation of y labels | PASS | 3 | 0.034 | | -| [test-text.R](testthat/test-text.R#L23) | adjust text sizes | set text sizes | PASS | 203 | 0.217 | | -| [test-text.R](testthat/test-text.R#L144) | adjust text colors | set text colors | PASS | 98 | 0.108 | | +|:-------------------------------------------------------|:---------------------|:----------------------------------------------------------------|:--------|----:|------:|:-----| +| [test-labs.R](testthat/test-labs.R#L29) | attr labs | easy\_labs uses column attrib | SKIPPED | 4 | 0.780 | ๐Ÿ”ถ | +| [test-labs.R](testthat/test-labs.R#L46_L47) | attr labs | regular labs overides easy\_labs | SKIPPED | 2 | 0.552 | ๐Ÿ”ถ | +| [test-labs.R](testthat/test-labs.R#L57_L58) | attr labs | regular labs pass new labels through easy\_labs | SKIPPED | 2 | 0.306 | ๐Ÿ”ถ | +| [test-labs.R](testthat/test-labs.R#L76_L77) | attr labs | column name used when no column attrib present | SKIPPED | 2 | 0.258 | ๐Ÿ”ถ | +| [test-legend.R](testthat/test-legend.R#L10) | remove legend | easy\_remove\_legend works with no argument | PASS | 1 | 0.020 | | +| [test-legend.R](testthat/test-legend.R#L16) | remove legend | easy\_remove\_legend works with single character argument | PASS | 1 | 0.019 | | +| [test-legend.R](testthat/test-legend.R#L22) | remove legend | easy\_remove\_legend works with single bare argument | PASS | 1 | 0.019 | | +| [test-legend.R](testthat/test-legend.R#L28) | remove legend | easy\_remove\_legend works with multiple character arguments | PASS | 1 | 0.033 | | +| [test-legend.R](testthat/test-legend.R#L34) | remove legend | easy\_remove\_legend works with multiple bare arguments | PASS | 1 | 0.024 | | +| [test-legend.R](testthat/test-legend.R#L41) | remove legend | easy\_remove\_legend teach = TRUE works with no other arguments | PASS | 2 | 0.008 | | +| [test-legend.R](testthat/test-legend.R#L49) | remove legend | easy\_remove\_legend teach = TRUE works with specific aes | PASS | 2 | 0.007 | | +| [test-legend.R](testthat/test-legend.R#L57) | remove legend | easy\_remove\_legend teach = TRUE works with multiple aes | PASS | 2 | 0.007 | | +| [test-legend.R](testthat/test-legend.R#L64) | move legend | easy\_change\_legend errors with no argument | PASS | 1 | 0.013 | | +| [test-legend.R](testthat/test-legend.R#L70) | move legend | easy\_change\_legend works with combinations | PASS | 4 | 0.133 | | +| [test-legend.R](testthat/test-legend.R#L85) | move legend | easy\_move\_legend works with no argument | PASS | 1 | 0.024 | | +| [test-legend.R](testthat/test-legend.R#L91) | move legend | easy\_move\_legend works with specified argument | PASS | 3 | 0.071 | | +| [test-legend.R](testthat/test-legend.R#L101) | move legend | easy\_move\_legend errors with bad argument | PASS | 1 | 0.011 | | +| [test-legend.R](testthat/test-legend.R#L107) | move legend | easy\_move\_legend aliases work | PASS | 3 | 0.075 | | +| [test-legend.R](testthat/test-legend.R#L119) | move legend | easy\_move\_legend teach = TRUE works with combinations | PASS | 4 | 0.041 | | +| [test-legend.R](testthat/test-legend.R#L128) | move legend | easy\_legend\_at teach = TRUE works with combinations | PASS | 4 | 0.031 | | +| [test-legend.R](testthat/test-legend.R#L137) | move legend | easy\_change\_legend teach = TRUE works with position | PASS | 3 | 0.036 | | +| [test-legend.R](testthat/test-legend.R#L147) | legend direction | easy\_rotate\_legend works with no argument | PASS | 1 | 0.020 | | +| [test-legend.R](testthat/test-legend.R#L153) | legend direction | easy\_rotate\_legend works with combinations | PASS | 4 | 0.076 | | +| [test-legend.R](testthat/test-legend.R#L168) | legend direction | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.030 | | +| [test-legend.R](testthat/test-legend.R#L179) | legend justification | easy\_adjust\_legend works with no argument | PASS | 1 | 0.019 | | +| [test-legend.R](testthat/test-legend.R#L185) | legend justification | easy\_adjust\_legend works with combinations | PASS | 3 | 0.056 | | +| [test-legend.R](testthat/test-legend.R#L195) | legend justification | easy\_adjust\_legend errors with bad argument | PASS | 1 | 0.009 | | +| [test-legend.R](testthat/test-legend.R#L201) | legend justification | easy\_adjust\_legend teach = TRUE works with justification | PASS | 3 | 0.038 | | +| [test-legend.R](testthat/test-legend.R#L209) | legend justification | easy\_change\_legend teach = TRUE works with justification | PASS | 3 | 0.028 | | +| [test-legend.R](testthat/test-legend.R#L217) | legend justification | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.031 | | +| [test-legend.R](testthat/test-legend.R#L226) | legend title | easy\_add\_legend\_title errors with no argument | PASS | 1 | 0.008 | | +| [test-legend.R](testthat/test-legend.R#L232) | legend title | easy\_add\_legend\_title relabels a single legend title | PASS | 1 | 0.019 | | +| [test-legend.R](testthat/test-legend.R#L239) | legend title | easy\_add\_legend\_title relabels all legend titles | PASS | 9 | 0.031 | | +| [test-legend.R](testthat/test-legend.R#L247) | legend title | easy\_add\_legend\_title teach = TRUE works with specific aes | PASS | 4 | 0.030 | | +| [test-legend.R](testthat/test-legend.R#L256) | legend title | easy\_add\_legend\_title teach = TRUE works with unspecific aes | PASS | 12 | 0.041 | | +| [test-legend.R](testthat/test-legend.R#L270) | legend title | easy\_remove\_legend\_title works | PASS | 1 | 0.021 | | +| [test-remove-axis.R](testthat/test-remove-axis.R#L15) | remove axes | no argument | PASS | 3 | 0.080 | | +| [test-remove-axis.R](testthat/test-remove-axis.R#L46) | remove axes | explicit axis | PASS | 10 | 0.172 | | +| [test-remove-axis.R](testthat/test-remove-axis.R#L90) | remove axes | multiple components | PASS | 4 | 0.081 | | +| [test-remove-axis.R](testthat/test-remove-axis.R#L109) | remove axes | teach argument produces working code | PASS | 3 | 0.016 | | +| [test-rotate.R](testthat/test-rotate.R#L10) | rotate labels | rotation of both labels | PASS | 17 | 0.171 | | +| [test-rotate.R](testthat/test-rotate.R#L64) | rotate labels | rotation of x labels | PASS | 3 | 0.064 | | +| [test-rotate.R](testthat/test-rotate.R#L79) | rotate labels | rotation of y labels | PASS | 3 | 0.054 | | +| [test-text.R](testthat/test-text.R#L25) | adjust text sizes | set text sizes | PASS | 203 | 0.364 | | +| [test-text.R](testthat/test-text.R#L146) | adjust text colors | set text colors | PASS | 98 | 0.175 | | +| [test-text.R](testthat/test-text.R#L220) | text alignment | easy\_center\_title works | PASS | 1 | 0.023 | | | Failed | Warning | Skipped | -| :----- | :------ | :------ | +|:-------|:--------|:--------| | ๐Ÿ›‘ | โš ๏ธ | ๐Ÿ”ถ |
-
- - Session Info + +Session Info + | Field | Value | -| :------- | :---------------------------- | -| Version | R version 3.6.2 (2019-12-12) | +|:---------|:------------------------------| +| Version | R version 4.0.3 (2020-10-10) | | Platform | x86\_64-pc-linux-gnu (64-bit) | -| Running | Pop\!\_OS 19.04 | +| Running | Pop!\_OS 20.10 | | Language | en\_AU | | Timezone | Australia/Adelaide | | Package | Version | -| :------- | :------ | -| testthat | 2.3.1 | -| covr | 3.4.0 | -| covrpage | 0.0.70 | +|:---------|:--------| +| testthat | 3.0.1 | +| covr | 3.5.1 | +| covrpage | 0.1 |
- diff --git a/tests/testthat/test-labs.R b/tests/testthat/test-labs.R index 734d976..78bcad7 100644 --- a/tests/testthat/test-labs.R +++ b/tests/testthat/test-labs.R @@ -3,6 +3,13 @@ library(labelled) library(ggplot2) library(ggeasy) +expect_eqNe <- function(...) expect_equal(..., check.environment = FALSE) + +expect_doppelganger <- function(title, fig, path = NULL, ...) { + testthat::skip_if_not_installed("vdiffr") + vdiffr::expect_doppelganger(title, fig, path = path, ...) +} + iris_labs <- iris lbl <- c('Sepal Length', 'Sepal Width', 'Petal Length', 'Petal Width', 'Flower Species') @@ -15,59 +22,59 @@ p <- ggplot2::ggplot(iris_labs, ggplot2::geom_line(ggplot2::aes(colour = Species)) test_that("easy_labs uses column attrib", { - + hard_res <- p + ggplot2::labs(x = 'Sepal Length', y = 'Sepal Width', colour = 'Flower Species') easy_res <- p + easy_labs() - - testthat::expect_equal(easy_res, hard_res) + + expect_eqNe(easy_res, hard_res) expect_message(p + easy_labs(teach = TRUE), regexp = "colour = 'Flower Species')") - + easy_res_test_teach <- p + easy_labs() teach_message <- capture_messages({p + easy_labs(teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, p + teach_res) - - vdiffr::expect_doppelganger("labels_attrib", easy_res) - + expect_eqNe(easy_res_test_teach, p + teach_res) + + expect_doppelganger("labels_attrib", easy_res) + }) testthat::test_that("regular labs overides easy_labs ", { - + hard_res <- p + ggplot2::labs(x = 'x axis', y = 'Sepal Width', colour = 'Flower Species') easy_res <- p + easy_labs(x = 'x axis') - - expect_equal(easy_res$labels[sort(names(easy_res$labels))], + + expect_eqNe(easy_res$labels[sort(names(easy_res$labels))], hard_res$labels[sort(names(hard_res$labels))]) - vdiffr::expect_doppelganger("labels_manual", easy_res) - + expect_doppelganger("labels_manual", easy_res) + }) testthat::test_that("regular labs pass new labels through easy_labs ", { - + hard_res <- p + ggplot2::labs(x = 'Sepal Length', y = 'Sepal Width', colour = 'Flower Species', title = 'my title') easy_res <- p + easy_labs(title = 'my title') - - expect_equal(easy_res$labels[sort(names(easy_res$labels))], + + expect_eqNe(easy_res$labels[sort(names(easy_res$labels))], hard_res$labels[sort(names(hard_res$labels))]) - vdiffr::expect_doppelganger("labels_mytitle", easy_res) - + expect_doppelganger("labels_mytitle", easy_res) + }) test_that("column name used when no column attrib present", { - + labelled::var_label(iris_labs$Sepal.Length) <- NULL - + p <- ggplot2::ggplot(iris_labs, ggplot2::aes(x = Sepal.Length, y = Sepal.Width)) + ggplot2::geom_line(ggplot2::aes(colour = Species)) - - + + hard_res <- p + ggplot2::labs(y = 'Sepal Width', colour = 'Flower Species') easy_res <- p + ggeasy::easy_labs() - - expect_equal(easy_res$labels[sort(names(easy_res$labels))], + + expect_eqNe(easy_res$labels[sort(names(easy_res$labels))], hard_res$labels[sort(names(hard_res$labels))]) - vdiffr::expect_doppelganger("labels_y_col", easy_res) - + expect_doppelganger("labels_y_col", easy_res) + }) diff --git a/tests/testthat/test-legend.R b/tests/testthat/test-legend.R index e0e5831..d2fd1db 100644 --- a/tests/testthat/test-legend.R +++ b/tests/testthat/test-legend.R @@ -1,35 +1,37 @@ context("remove legend") +expect_eqNe <- function(...) expect_equal(..., check.environment = FALSE) + p <- ggplot2::ggplot(mtcars, ggplot2::aes(wt, mpg, colour = cyl, size = hp)) + ggplot2::geom_point() test_that("easy_remove_legend works with no argument", { easy_res <- p + easy_remove_legend() hard_res <- p + theme(legend.position = "none") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_remove_legend works with single character argument", { easy_res <- p + easy_remove_legend("size") hard_res <- p + guides(size = FALSE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_remove_legend works with single bare argument", { easy_res <- p + easy_remove_legend(size) hard_res <- p + guides(size = FALSE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_remove_legend works with multiple character arguments", { easy_res <- p + easy_remove_legend("size", "color") hard_res <- p + guides(size = FALSE, color = FALSE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_remove_legend works with multiple bare arguments", { easy_res <- p + easy_remove_legend(size, color) hard_res <- p + guides(size = FALSE, color = FALSE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_remove_legend teach = TRUE works with no other arguments", { @@ -37,7 +39,7 @@ test_that("easy_remove_legend teach = TRUE works with no other arguments", { easy_res <- easy_remove_legend() teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) expect_message(p + easy_remove_legend(teach = TRUE)) - expect_equal(easy_res, teach_res) + expect_eqNe(easy_res, teach_res) }) test_that("easy_remove_legend teach = TRUE works with specific aes", { @@ -45,7 +47,7 @@ test_that("easy_remove_legend teach = TRUE works with specific aes", { easy_res <- easy_remove_legend(size) teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) expect_message(p + easy_remove_legend(size, teach = TRUE)) - expect_equal(easy_res, teach_res) + expect_eqNe(easy_res, teach_res) }) test_that("easy_remove_legend teach = TRUE works with multiple aes", { @@ -53,7 +55,7 @@ test_that("easy_remove_legend teach = TRUE works with multiple aes", { easy_res <- easy_remove_legend(size, color) teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) expect_message(p + easy_remove_legend(size, teach = TRUE)) - expect_equal(easy_res, teach_res) + expect_eqNe(easy_res, teach_res) }) context("move legend") @@ -65,34 +67,34 @@ test_that("easy_change_legend errors with no argument", { test_that("easy_change_legend works with combinations", { easy_res <- p + easy_change_legend("position", "right") hard_res <- p + theme(legend.position = "right") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_change_legend("position", "bottom") hard_res <- p + theme(legend.position = "bottom") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_change_legend("position", "top") hard_res <- p + theme(legend.position = "top") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_change_legend("position", "left") hard_res <- p + theme(legend.position = "left") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_move_legend works with no argument", { easy_res <- p + easy_move_legend() hard_res <- p + theme(legend.position = "right") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_move_legend works with specified argument", { easy_res <- p + easy_move_legend("bottom") hard_res <- p + theme(legend.position = "bottom") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_move_legend("top") hard_res <- p + theme(legend.position = "top") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_move_legend("left") hard_res <- p + theme(legend.position = "left") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_move_legend errors with bad argument", { @@ -102,13 +104,13 @@ test_that("easy_move_legend errors with bad argument", { test_that("easy_move_legend aliases work", { easy_res <- p + easy_legend_at("bottom") hard_res <- p + theme(legend.position = "bottom") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_legend_at("top") hard_res <- p + theme(legend.position = "top") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_legend_at("left") hard_res <- p + theme(legend.position = "left") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_move_legend teach = TRUE works with combinations", { @@ -117,7 +119,7 @@ test_that("easy_move_legend teach = TRUE works with combinations", { expect_message(p + easy_move_legend("bottom", teach = TRUE), regexp = 'easy_move_legend("bottom")', fixed = TRUE) expect_message(p + easy_move_legend("bottom", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_move_legend("bottom", teach = TRUE), regexp = 'theme(legend.position = "bottom")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_legend_at teach = TRUE works with combinations", { @@ -126,7 +128,7 @@ test_that("easy_legend_at teach = TRUE works with combinations", { expect_message(p + easy_legend_at("bottom", teach = TRUE), regexp = 'easy_legend_at("bottom")', fixed = TRUE) expect_message(p + easy_legend_at("bottom", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_legend_at("bottom", teach = TRUE), regexp = 'theme(legend.position = "bottom")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_change_legend teach = TRUE works with position", { @@ -134,7 +136,7 @@ test_that("easy_change_legend teach = TRUE works with position", { hard_res <- p + theme(legend.position = "bottom") expect_message(p + easy_change_legend("position", "bottom", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_change_legend("position", "bottom", teach = TRUE), regexp = 'theme(legend.position = "bottom")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) context("legend direction") @@ -142,22 +144,22 @@ context("legend direction") test_that("easy_rotate_legend works with no argument", { easy_res <- p + easy_rotate_legend() hard_res <- p + theme(legend.direction = "vertical") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_rotate_legend works with combinations", { easy_res <- p + easy_change_legend("direction", "vertical") hard_res <- p + theme(legend.direction = "vertical") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_change_legend("direction", "horizontal") hard_res <- p + theme(legend.direction = "horizontal") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_rotate_legend("vertical") hard_res <- p + theme(legend.direction = "vertical") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_rotate_legend("horizontal") hard_res <- p + theme(legend.direction = "horizontal") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_rotate_legend teach = TRUE works with combinations", { @@ -166,7 +168,7 @@ test_that("easy_rotate_legend teach = TRUE works with combinations", { expect_message(p + easy_rotate_legend("horizontal", teach = TRUE), regexp = 'easy_rotate_legend("horizontal"', fixed = TRUE) expect_message(p + easy_rotate_legend("horizontal", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_rotate_legend("horizontal", teach = TRUE), regexp = 'theme(legend.direction = "horizontal")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) context("legend justification") @@ -174,19 +176,19 @@ context("legend justification") test_that("easy_adjust_legend works with no argument", { easy_res <- p + easy_adjust_legend() hard_res <- p + theme(legend.justification = "left") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_adjust_legend works with combinations", { easy_res <- p + easy_change_legend("justification", "left") hard_res <- p + theme(legend.justification = "left") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_change_legend("justification", "right") hard_res <- p + theme(legend.justification = "right") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) easy_res <- p + easy_change_legend("justification", "center") hard_res <- p + theme(legend.justification = "center") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_adjust_legend errors with bad argument", { @@ -198,7 +200,7 @@ test_that("easy_adjust_legend teach = TRUE works with justification", { hard_res <- p + theme(legend.justification = "right") expect_message(p + easy_adjust_legend("right", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_adjust_legend("right", teach = TRUE), regexp = 'theme(legend.justification = "right")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_change_legend teach = TRUE works with justification", { @@ -206,7 +208,7 @@ test_that("easy_change_legend teach = TRUE works with justification", { hard_res <- p + theme(legend.justification = "center") expect_message(p + easy_change_legend("justification", "center", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_change_legend("justification", "center", teach = TRUE), regexp = 'theme(legend.justification = "center")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_rotate_legend teach = TRUE works with combinations", { @@ -215,7 +217,7 @@ test_that("easy_rotate_legend teach = TRUE works with combinations", { expect_message(p + easy_rotate_legend("horizontal", teach = TRUE), regexp = 'easy_rotate_legend("horizontal"', fixed = TRUE) expect_message(p + easy_rotate_legend("horizontal", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_rotate_legend("horizontal", teach = TRUE), regexp = 'theme(legend.direction = "horizontal")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) context("legend title") @@ -227,16 +229,16 @@ test_that("easy_add_legend_title errors with no argument", { test_that("easy_add_legend_title relabels a single legend title", { easy_res <- p + easy_add_legend_title(col = "nCylinders") hard_res <- p + labs(col = "nCylinders") - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_add_legend_title relabels all legend titles", { easy_res <- p + easy_add_legend_title("title") hard_res <- p + labs(colour = "title", size = "title") for (el in setdiff(names(hard_res), "labels")) { - expect_equal(easy_res[[el]], hard_res[[el]]) + expect_eqNe(easy_res[[el]], hard_res[[el]]) } - expect_equal(easy_res$labels[c("size", "colour")], hard_res$labels[c("size", "colour")]) + expect_eqNe(easy_res$labels[c("size", "colour")], hard_res$labels[c("size", "colour")]) }) test_that("easy_add_legend_title teach = TRUE works with specific aes", { @@ -245,7 +247,7 @@ test_that("easy_add_legend_title teach = TRUE works with specific aes", { expect_message(p + easy_add_legend_title(col = "nCylinders", teach = TRUE), regexp = 'easy_add_legend_title(col = "nCylinders"', fixed = TRUE) expect_message(p + easy_add_legend_title(col = "nCylinders", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_add_legend_title(col = "nCylinders", teach = TRUE), regexp = 'labs(col = "nCylinders")', fixed = TRUE) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) test_that("easy_add_legend_title teach = TRUE works with unspecific aes", { @@ -255,9 +257,9 @@ test_that("easy_add_legend_title teach = TRUE works with unspecific aes", { expect_message(p + easy_add_legend_title("title", teach = TRUE), regexp = 'can be substituted with:', fixed = TRUE) expect_message(p + easy_add_legend_title("title", teach = TRUE), regexp = 'labs(YOUR_AES = "title")', fixed = TRUE) for (el in setdiff(names(hard_res), "labels")) { - expect_equal(easy_res[[el]], hard_res[[el]]) + expect_eqNe(easy_res[[el]], hard_res[[el]]) } - expect_equal(easy_res$labels[c("size", "colour")], hard_res$labels[c("size", "colour")]) + expect_eqNe(easy_res$labels[c("size", "colour")], hard_res$labels[c("size", "colour")]) }) @@ -265,5 +267,5 @@ test_that("easy_add_legend_title teach = TRUE works with unspecific aes", { test_that("easy_remove_legend_title works", { easy_res <- p + easy_remove_legend_title() hard_res <- p + ggplot2::theme(legend.title = ggplot2::element_blank()) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) diff --git a/tests/testthat/test-remove-axis.R b/tests/testthat/test-remove-axis.R index 826880d..2a6cb28 100644 --- a/tests/testthat/test-remove-axis.R +++ b/tests/testthat/test-remove-axis.R @@ -1,5 +1,7 @@ context("remove axes") +expect_eqNe <- function(...) expect_equal(..., check.environment = FALSE) + p <- ggplot2::ggplot(mtcars, ggplot2::aes(mpg, hp)) + geom_point() test_that("no argument", { @@ -10,7 +12,7 @@ test_that("no argument", { axis.text = ggplot2::element_blank() ) easy_res_no_arg_both <- p + easy_remove_axes() - expect_equal(hard_res_no_arg_both, easy_res_no_arg_both) + expect_eqNe(hard_res_no_arg_both, easy_res_no_arg_both) hard_res_no_arg_x <- p + ggplot2::theme( axis.title.x = ggplot2::element_blank(), @@ -19,7 +21,7 @@ test_that("no argument", { axis.text.x = ggplot2::element_blank() ) easy_res_no_arg_x <- p + easy_remove_x_axis() - expect_equal(hard_res_no_arg_x, easy_res_no_arg_x) + expect_eqNe(hard_res_no_arg_x, easy_res_no_arg_x) hard_res_no_arg_y <- p + ggplot2::theme( axis.title.y = ggplot2::element_blank(), @@ -28,7 +30,7 @@ test_that("no argument", { axis.text.y = ggplot2::element_blank() ) easy_res_no_arg_y <- p + easy_remove_y_axis() - expect_equal(hard_res_no_arg_y, easy_res_no_arg_y) + expect_eqNe(hard_res_no_arg_y, easy_res_no_arg_y) }) @@ -41,40 +43,40 @@ test_that("explicit axis", { ) easy_res_x_all <- p + easy_remove_axes("x") easy_res_x_all_call <- p + easy_remove_x_axis() - expect_equal(hard_res_x_all, easy_res_x_all) - expect_equal(hard_res_x_all, easy_res_x_all_call) + expect_eqNe(hard_res_x_all, easy_res_x_all) + expect_eqNe(hard_res_x_all, easy_res_x_all_call) hard_res_x_ticks <- p + ggplot2::theme( axis.ticks.x = ggplot2::element_blank(), ) easy_res_x_ticks <- p + easy_remove_axes("x", "ticks") easy_res_x_ticks_call <- p + easy_remove_x_axis("ticks") - expect_equal(hard_res_x_ticks, easy_res_x_ticks) - expect_equal(hard_res_x_ticks, easy_res_x_ticks_call) + expect_eqNe(hard_res_x_ticks, easy_res_x_ticks) + expect_eqNe(hard_res_x_ticks, easy_res_x_ticks_call) hard_res_x_title <- p + ggplot2::theme( axis.title.x = ggplot2::element_blank(), ) easy_res_x_title <- p + easy_remove_axes("x", "title") easy_res_x_title_call <- p + easy_remove_x_axis("title") - expect_equal(hard_res_x_title, easy_res_x_title) - expect_equal(hard_res_x_title, easy_res_x_title_call) + expect_eqNe(hard_res_x_title, easy_res_x_title) + expect_eqNe(hard_res_x_title, easy_res_x_title_call) hard_res_x_line <- p + ggplot2::theme( axis.line.x = ggplot2::element_blank(), ) easy_res_x_line <- p + easy_remove_axes("x", "line") easy_res_x_line_call <- p + easy_remove_x_axis("line") - expect_equal(hard_res_x_line, easy_res_x_line) - expect_equal(hard_res_x_line, easy_res_x_line_call) + expect_eqNe(hard_res_x_line, easy_res_x_line) + expect_eqNe(hard_res_x_line, easy_res_x_line_call) hard_res_x_text <- p + ggplot2::theme( axis.text.x = ggplot2::element_blank(), ) easy_res_x_text <- p + easy_remove_axes("x", "text") easy_res_x_text_call <- p + easy_remove_x_axis("text") - expect_equal(hard_res_x_text, easy_res_x_text) - expect_equal(hard_res_x_text, easy_res_x_text_call) + expect_eqNe(hard_res_x_text, easy_res_x_text) + expect_eqNe(hard_res_x_text, easy_res_x_text_call) }) @@ -85,8 +87,8 @@ test_that("multiple components", { ) easy_res_x_tickstitle <- p + easy_remove_axes("x", c("ticks", "title")) easy_res_x_tickstitle_call <- p + easy_remove_x_axis(c("ticks", "title")) - expect_equal(hard_res_x_tickstitle, easy_res_x_tickstitle) - expect_equal(hard_res_x_tickstitle, easy_res_x_tickstitle_call) + expect_eqNe(hard_res_x_tickstitle, easy_res_x_tickstitle) + expect_eqNe(hard_res_x_tickstitle, easy_res_x_tickstitle_call) hard_res_both_tickstitle <- p + ggplot2::theme( axis.title = ggplot2::element_blank(), @@ -95,8 +97,8 @@ test_that("multiple components", { easy_res_both_noarg_tickstitle <- p + easy_remove_axes(what = c("ticks", "title")) easy_res_both_tickstitle <- p + easy_remove_axes("both", c("ticks", "title")) easy_res_both_tickstitle_call <- p + easy_remove_axes("both", c("ticks", "title")) - expect_equal(hard_res_both_tickstitle, easy_res_both_tickstitle) - expect_equal(hard_res_x_tickstitle, easy_res_x_tickstitle_call) + expect_eqNe(hard_res_both_tickstitle, easy_res_both_tickstitle) + expect_eqNe(hard_res_x_tickstitle, easy_res_x_tickstitle_call) }) @@ -104,15 +106,15 @@ test_that("teach argument produces working code", { easy_res_test_teach <- easy_remove_axes(what = c("ticks", "title")) teach_message <- capture_messages({p + easy_remove_axes(what = c("ticks", "title"), teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, teach_res) + expect_eqNe(easy_res_test_teach, teach_res) easy_res_test_teach <- easy_remove_axes("x", what = c("ticks", "title")) teach_message <- capture_messages({p + easy_remove_x_axis(what = c("ticks", "title"), teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, teach_res) + expect_eqNe(easy_res_test_teach, teach_res) easy_res_test_teach <- easy_remove_axes() teach_message <- capture_messages({p + easy_remove_axes(teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, teach_res) + expect_eqNe(easy_res_test_teach, teach_res) }) diff --git a/tests/testthat/test-rotate.R b/tests/testthat/test-rotate.R index c099d20..61b89f4 100644 --- a/tests/testthat/test-rotate.R +++ b/tests/testthat/test-rotate.R @@ -1,27 +1,29 @@ context("rotate labels") +expect_eqNe <- function(...) expect_equal(..., check.environment = FALSE) + p <- ggplot2::ggplot(mtcars, ggplot2::aes(mpg, hp)) + geom_point() test_that("rotation of both labels", { hard_res_both_90_left <- p + ggplot2::theme(axis.text = element_text(angle = 90, hjust = 0)) easy_res_both_90_left <- p + easy_rotate_labels(side = "left") - expect_equal(hard_res_both_90_left, easy_res_both_90_left) + expect_eqNe(hard_res_both_90_left, easy_res_both_90_left) hard_res_both_90_right <- p + ggplot2::theme(axis.text = element_text(angle = 90, hjust = 1)) easy_res_both_90_right <- p + easy_rotate_labels(side = "right") - expect_equal(hard_res_both_90_right, easy_res_both_90_right) + expect_eqNe(hard_res_both_90_right, easy_res_both_90_right) hard_res_both_45_right <- p + ggplot2::theme(axis.text = element_text(angle = 45, hjust = 1)) easy_res_both_45_right <- p + easy_rotate_labels(angle = 45, side = "right") - expect_equal(hard_res_both_45_right, easy_res_both_45_right) + expect_eqNe(hard_res_both_45_right, easy_res_both_45_right) hard_res_both_top_right <- p + ggplot2::theme(axis.text = element_text(angle = -90, hjust = 1)) easy_res_both_top_right <- p + easy_rotate_labels(angle = "startattop", side = "right") - expect_equal(hard_res_both_top_right, easy_res_both_top_right) + expect_eqNe(hard_res_both_top_right, easy_res_both_top_right) hard_res_both_bottom_right <- p + ggplot2::theme(axis.text = element_text(angle = 90, hjust = 1)) easy_res_both_bottom_right <- p + easy_rotate_labels(angle = "startatbottom", side = "right") - expect_equal(hard_res_both_bottom_right, easy_res_both_bottom_right) + expect_eqNe(hard_res_both_bottom_right, easy_res_both_bottom_right) ## correct values in teach expect_message(p + easy_rotate_labels(side = "left", teach = TRUE), regexp = "angle = 90, hjust = 0") @@ -37,17 +39,17 @@ test_that("rotation of both labels", { easy_res_test_teach <- easy_rotate_labels(angle = 45, side = "right") teach_message <- capture_messages({p + easy_rotate_labels(angle = 45, side = "right", teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, teach_res) + expect_eqNe(easy_res_test_teach, teach_res) easy_res_test_teach <- easy_rotate_labels(angle = "startattop", side = "right") teach_message <- capture_messages({p + easy_rotate_labels(angle = "startattop", side = "right", teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, teach_res) + expect_eqNe(easy_res_test_teach, teach_res) easy_res_test_teach <- easy_rotate_x_labels(angle = 45, side = "right") teach_message <- capture_messages({p + easy_rotate_x_labels(angle = 45, side = "right", teach = TRUE)})[2] teach_res <- rlang::eval_bare(rlang::parse_expr(teach_message)) - expect_equal(easy_res_test_teach, teach_res) + expect_eqNe(easy_res_test_teach, teach_res) ## unrecognised values expect_error(p + easy_rotate_labels(which = "foo"), regexp = "should be one of") @@ -59,28 +61,28 @@ test_that("rotation of both labels", { test_that("rotation of x labels", { hard_res_x_90_left <- p + ggplot2::theme(axis.text.x = element_text(angle = 90, hjust = 0)) easy_res_x_90_left <- p + easy_rotate_x_labels(side = "left") - expect_equal(hard_res_x_90_left, easy_res_x_90_left) + expect_eqNe(hard_res_x_90_left, easy_res_x_90_left) hard_res_x_90_right <- p + ggplot2::theme(axis.text.x = element_text(angle = 90, hjust = 1)) easy_res_x_90_right <- p + easy_rotate_x_labels(side = "right") - expect_equal(hard_res_x_90_right, easy_res_x_90_right) + expect_eqNe(hard_res_x_90_right, easy_res_x_90_right) hard_res_x_45_right <- p + ggplot2::theme(axis.text.x = element_text(angle = 45, hjust = 1)) easy_res_x_45_right <- p + easy_rotate_x_labels(angle = 45, side = "right") - expect_equal(hard_res_x_45_right, easy_res_x_45_right) + expect_eqNe(hard_res_x_45_right, easy_res_x_45_right) }) test_that("rotation of y labels", { hard_res_y_90_left <- p + ggplot2::theme(axis.text.y = element_text(angle = 90, hjust = 0)) easy_res_y_90_left <- p + easy_rotate_y_labels(side = "left") - expect_equal(hard_res_y_90_left, easy_res_y_90_left) + expect_eqNe(hard_res_y_90_left, easy_res_y_90_left) hard_res_y_90_right <- p + ggplot2::theme(axis.text.y = element_text(angle = 90, hjust = 1)) easy_res_y_90_right <- p + easy_rotate_y_labels(side = "right") - expect_equal(hard_res_y_90_right, easy_res_y_90_right) + expect_eqNe(hard_res_y_90_right, easy_res_y_90_right) hard_res_y_45_right <- p + ggplot2::theme(axis.text.y = element_text(angle = 45, hjust = 1)) easy_res_y_45_right <- p + easy_rotate_y_labels(angle = 45, side = "right") - expect_equal(hard_res_y_45_right, easy_res_y_45_right) + expect_eqNe(hard_res_y_45_right, easy_res_y_45_right) }) diff --git a/tests/testthat/test-text.R b/tests/testthat/test-text.R index 68fdf7f..cea0ee6 100644 --- a/tests/testthat/test-text.R +++ b/tests/testthat/test-text.R @@ -1,10 +1,12 @@ context("adjust text sizes") +expect_eqNe <- function(...) expect_equal(..., check.environment = FALSE) + expect_equal_with_reorder <- function(easy, hard, debug = FALSE) { for (x in names(hard)) { for (y in names(hard[x])) { if (debug) message("testing: ", x, "[", y, "]") - expect_equal(hard[[x]][[y]], easy[[x]][[y]]) + expect_eqNe(hard[[x]][[y]], easy[[x]][[y]]) } } } @@ -215,5 +217,5 @@ context("text alignment") test_that("easy_center_title works", { easy_res <- p + easy_center_title() hard_res <- p + ggplot2::theme(plot.title = element_text(hjust = .5)) - expect_equal(easy_res, hard_res) + expect_eqNe(easy_res, hard_res) }) diff --git a/vignettes/tests_and_coverage.R b/vignettes/tests_and_coverage.R deleted file mode 100644 index e4f5ace..0000000 --- a/vignettes/tests_and_coverage.R +++ /dev/null @@ -1,7 +0,0 @@ -## ----setup, include = FALSE---------------------------------------------- -knitr::opts_chunk$set( - collapse = TRUE, - comment = "#>", - eval = FALSE -) - diff --git a/vignettes/tests_and_coverage.Rmd b/vignettes/tests_and_coverage.Rmd index 5e85402..4419256 100644 --- a/vignettes/tests_and_coverage.Rmd +++ b/vignettes/tests_and_coverage.Rmd @@ -3,7 +3,7 @@ title: "Tests and Coverage" date: "`r format(Sys.time(), '%d %B, %Y %H:%M:%S')`" output: rmarkdown::html_vignette vignette: > - %\VignetteIndexEntry{covrpage: Tests and Coverage} + %\VignetteIndexEntry{Tests and Coverage} %\VignetteEngine{knitr::rmarkdown} %\VignetteEncoding{UTF-8} --- @@ -17,8 +17,11 @@ knitr::opts_chunk$set( ``` +- [Coverage](#coverage) +- [Unit Tests](#unit-tests) + This output is created by -[covrpage](https://github.com/metrumresearchgroup/covrpage). +[covrpage](https://github.com/yonicd/covrpage). ## Coverage @@ -26,106 +29,106 @@ Coverage summary is created using the [covr](https://github.com/r-lib/covr) package. | Object | Coverage (%) | -| :-------------------------- | :----------: | -| ggeasy | 100 | -| [R/axis.R](https://github.com/jonocarroll/ggeasy/tree/master/R/axis.R) | 100 | -| [R/labs.R](https://github.com/jonocarroll/ggeasy/tree/master/R/labs.R) | 100 | -| [R/labs2.R](https://github.com/jonocarroll/ggeasy/tree/master/R/labs2.R) | 100 | -| [R/legend.R](https://github.com/jonocarroll/ggeasy/tree/master/R/legend.R) | 100 | -| [R/text.R](https://github.com/jonocarroll/ggeasy/tree/master/R/text.R) | 100 | +|:----------------------------|:------------:| +| ggeasy | 96.53 | +| [R/legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/R/legend.R) | 90.54 | +| [R/axis.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/R/axis.R) | 100.00 | +| [R/labs.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/R/labs.R) | 100.00 | +| [R/labs2.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/R/labs2.R) | 100.00 | +| [R/text.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/R/text.R) | 100.00 |
## Unit Tests Unit Test summary is created using the -[testthat](https://github.com/r-lib/testthat) -package. +[testthat](https://github.com/r-lib/testthat) package. -| file | n | time | error | failed | skipped | warning | icon | -| :------------------------------------------------ | -: | ----: | ----: | -----: | ------: | ------: | :--- | -| [test-labs.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-labs.R) | 10 | 1.227 | 0 | 0 | 4 | 0 | ๐Ÿ”ถ | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R) | 86 | 0.638 | 0 | 0 | 0 | 0 | | -| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-remove-axis.R) | 20 | 0.238 | 0 | 0 | 0 | 0 | | -| [test-rotate.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-rotate.R) | 23 | 0.198 | 0 | 0 | 0 | 0 | | -| [test-text.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-text.R) | 61 | 0.586 | 0 | 0 | 0 | 0 | | +| file | n | time | error | failed | skipped | warning | icon | +|:--------------------------------------------------|----:|------:|------:|-------:|--------:|--------:|:-----| +| [test-labs.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-labs.R) | 10 | 1.896 | 0 | 0 | 4 | 0 | ๐Ÿ”ถ | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R) | 87 | 1.029 | 0 | 0 | 0 | 0 | | +| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-remove-axis.R) | 20 | 0.349 | 0 | 0 | 0 | 0 | | +| [test-rotate.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-rotate.R) | 23 | 0.289 | 0 | 0 | 0 | 0 | | +| [test-text.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-text.R) | 302 | 0.562 | 0 | 0 | 0 | 0 | |
- - Show Detailed Test Results + +Show Detailed Test Results -| file | context | test | status | n | time | icon | -| :----------------------------------------------------- | :------------------- | :-------------------------------------------------------------- | :------ | -: | ----: | :--- | -| [test-labs.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-labs.R#L22) | attr labs | easy\_labs uses column attrib | SKIPPED | 4 | 0.338 | ๐Ÿ”ถ | -| [test-labs.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-labs.R#L39_L40) | attr labs | regular labs overides easy\_labs | SKIPPED | 2 | 0.435 | ๐Ÿ”ถ | -| [test-labs.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-labs.R#L50_L51) | attr labs | regular labs pass new labels through easy\_labs | SKIPPED | 2 | 0.222 | ๐Ÿ”ถ | -| [test-labs.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-labs.R#L69_L70) | attr labs | column name used when no column attrib present | SKIPPED | 2 | 0.232 | ๐Ÿ”ถ | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L8) | remove legend | easy\_remove\_legend works with no argument | PASS | 1 | 0.013 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L14) | remove legend | easy\_remove\_legend works with single character argument | PASS | 1 | 0.011 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L20) | remove legend | easy\_remove\_legend works with single bare argument | PASS | 1 | 0.015 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L26) | remove legend | easy\_remove\_legend works with multiple character arguments | PASS | 1 | 0.016 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L32) | remove legend | easy\_remove\_legend works with multiple bare arguments | PASS | 1 | 0.023 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L39) | remove legend | easy\_remove\_legend teach = TRUE works with no other arguments | PASS | 2 | 0.005 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L47) | remove legend | easy\_remove\_legend teach = TRUE works with specific aes | PASS | 2 | 0.005 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L55) | remove legend | easy\_remove\_legend teach = TRUE works with multiple aes | PASS | 2 | 0.004 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L62) | move legend | easy\_change\_legend errors with no argument | PASS | 1 | 0.001 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L68) | move legend | easy\_change\_legend works with combinations | PASS | 4 | 0.061 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L83) | move legend | easy\_move\_legend works with no argument | PASS | 1 | 0.022 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L89) | move legend | easy\_move\_legend works with specified argument | PASS | 3 | 0.040 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L99) | move legend | easy\_move\_legend errors with bad argument | PASS | 1 | 0.001 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L105) | move legend | easy\_move\_legend aliases work | PASS | 3 | 0.046 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L117) | move legend | easy\_move\_legend teach = TRUE works with combinations | PASS | 4 | 0.022 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L126) | move legend | easy\_legend\_at teach = TRUE works with combinations | PASS | 4 | 0.021 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L135) | move legend | easy\_change\_legend teach = TRUE works with position | PASS | 3 | 0.017 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L145) | legend direction | easy\_rotate\_legend works with no argument | PASS | 1 | 0.013 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L151) | legend direction | easy\_rotate\_legend works with combinations | PASS | 4 | 0.062 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L166) | legend direction | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.020 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L177) | legend justification | easy\_adjust\_legend works with no argument | PASS | 1 | 0.016 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L183) | legend justification | easy\_adjust\_legend works with combinations | PASS | 3 | 0.054 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L193) | legend justification | easy\_adjust\_legend errors with bad argument | PASS | 1 | 0.001 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L199) | legend justification | easy\_adjust\_legend teach = TRUE works with justification | PASS | 3 | 0.019 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L207) | legend justification | easy\_change\_legend teach = TRUE works with justification | PASS | 3 | 0.018 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L215) | legend justification | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.019 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L224) | legend title | easy\_add\_legend\_title errors with no argument | PASS | 1 | 0.001 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L230) | legend title | easy\_add\_legend\_title relabels a single legend title | PASS | 1 | 0.032 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L237) | legend title | easy\_add\_legend\_title relabels all legend titles | PASS | 9 | 0.020 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L245) | legend title | easy\_add\_legend\_title teach = TRUE works with specific aes | PASS | 4 | 0.017 | | -| [test-legend.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-legend.R#L254) | legend title | easy\_add\_legend\_title teach = TRUE works with unspecific aes | PASS | 12 | 0.023 | | -| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-remove-axis.R#L13) | remove axes | no argument | PASS | 3 | 0.056 | | -| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-remove-axis.R#L44) | remove axes | explicit axis | PASS | 10 | 0.117 | | -| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-remove-axis.R#L88) | remove axes | multiple components | PASS | 4 | 0.054 | | -| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-remove-axis.R#L107) | remove axes | teach argument produces working code | PASS | 3 | 0.011 | | -| [test-rotate.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-rotate.R#L8) | rotate labels | rotation of both labels | PASS | 17 | 0.109 | | -| [test-rotate.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-rotate.R#L62) | rotate labels | rotation of x labels | PASS | 3 | 0.039 | | -| [test-rotate.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-rotate.R#L77) | rotate labels | rotation of y labels | PASS | 3 | 0.050 | | -| [test-text.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-text.R#L14) | adjust text sizes | set text sizes | PASS | 43 | 0.387 | | -| [test-text.R](https://github.com/jonocarroll/ggeasy/tree/master/tests/testthat/test-text.R#L135) | adjust text colors | set text colors | PASS | 18 | 0.199 | | +| file | context | test | status | n | time | icon | +|:-------------------------------------------------------|:---------------------|:----------------------------------------------------------------|:--------|----:|------:|:-----| +| [test-labs.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-labs.R#L29) | attr labs | easy\_labs uses column attrib | SKIPPED | 4 | 0.780 | ๐Ÿ”ถ | +| [test-labs.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-labs.R#L46_L47) | attr labs | regular labs overides easy\_labs | SKIPPED | 2 | 0.552 | ๐Ÿ”ถ | +| [test-labs.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-labs.R#L57_L58) | attr labs | regular labs pass new labels through easy\_labs | SKIPPED | 2 | 0.306 | ๐Ÿ”ถ | +| [test-labs.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-labs.R#L76_L77) | attr labs | column name used when no column attrib present | SKIPPED | 2 | 0.258 | ๐Ÿ”ถ | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L10) | remove legend | easy\_remove\_legend works with no argument | PASS | 1 | 0.020 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L16) | remove legend | easy\_remove\_legend works with single character argument | PASS | 1 | 0.019 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L22) | remove legend | easy\_remove\_legend works with single bare argument | PASS | 1 | 0.019 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L28) | remove legend | easy\_remove\_legend works with multiple character arguments | PASS | 1 | 0.033 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L34) | remove legend | easy\_remove\_legend works with multiple bare arguments | PASS | 1 | 0.024 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L41) | remove legend | easy\_remove\_legend teach = TRUE works with no other arguments | PASS | 2 | 0.008 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L49) | remove legend | easy\_remove\_legend teach = TRUE works with specific aes | PASS | 2 | 0.007 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L57) | remove legend | easy\_remove\_legend teach = TRUE works with multiple aes | PASS | 2 | 0.007 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L64) | move legend | easy\_change\_legend errors with no argument | PASS | 1 | 0.013 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L70) | move legend | easy\_change\_legend works with combinations | PASS | 4 | 0.133 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L85) | move legend | easy\_move\_legend works with no argument | PASS | 1 | 0.024 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L91) | move legend | easy\_move\_legend works with specified argument | PASS | 3 | 0.071 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L101) | move legend | easy\_move\_legend errors with bad argument | PASS | 1 | 0.011 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L107) | move legend | easy\_move\_legend aliases work | PASS | 3 | 0.075 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L119) | move legend | easy\_move\_legend teach = TRUE works with combinations | PASS | 4 | 0.041 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L128) | move legend | easy\_legend\_at teach = TRUE works with combinations | PASS | 4 | 0.031 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L137) | move legend | easy\_change\_legend teach = TRUE works with position | PASS | 3 | 0.036 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L147) | legend direction | easy\_rotate\_legend works with no argument | PASS | 1 | 0.020 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L153) | legend direction | easy\_rotate\_legend works with combinations | PASS | 4 | 0.076 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L168) | legend direction | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.030 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L179) | legend justification | easy\_adjust\_legend works with no argument | PASS | 1 | 0.019 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L185) | legend justification | easy\_adjust\_legend works with combinations | PASS | 3 | 0.056 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L195) | legend justification | easy\_adjust\_legend errors with bad argument | PASS | 1 | 0.009 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L201) | legend justification | easy\_adjust\_legend teach = TRUE works with justification | PASS | 3 | 0.038 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L209) | legend justification | easy\_change\_legend teach = TRUE works with justification | PASS | 3 | 0.028 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L217) | legend justification | easy\_rotate\_legend teach = TRUE works with combinations | PASS | 4 | 0.031 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L226) | legend title | easy\_add\_legend\_title errors with no argument | PASS | 1 | 0.008 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L232) | legend title | easy\_add\_legend\_title relabels a single legend title | PASS | 1 | 0.019 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L239) | legend title | easy\_add\_legend\_title relabels all legend titles | PASS | 9 | 0.031 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L247) | legend title | easy\_add\_legend\_title teach = TRUE works with specific aes | PASS | 4 | 0.030 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L256) | legend title | easy\_add\_legend\_title teach = TRUE works with unspecific aes | PASS | 12 | 0.041 | | +| [test-legend.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-legend.R#L270) | legend title | easy\_remove\_legend\_title works | PASS | 1 | 0.021 | | +| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-remove-axis.R#L15) | remove axes | no argument | PASS | 3 | 0.080 | | +| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-remove-axis.R#L46) | remove axes | explicit axis | PASS | 10 | 0.172 | | +| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-remove-axis.R#L90) | remove axes | multiple components | PASS | 4 | 0.081 | | +| [test-remove-axis.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-remove-axis.R#L109) | remove axes | teach argument produces working code | PASS | 3 | 0.016 | | +| [test-rotate.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-rotate.R#L10) | rotate labels | rotation of both labels | PASS | 17 | 0.171 | | +| [test-rotate.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-rotate.R#L64) | rotate labels | rotation of x labels | PASS | 3 | 0.064 | | +| [test-rotate.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-rotate.R#L79) | rotate labels | rotation of y labels | PASS | 3 | 0.054 | | +| [test-text.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-text.R#L25) | adjust text sizes | set text sizes | PASS | 203 | 0.364 | | +| [test-text.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-text.R#L146) | adjust text colors | set text colors | PASS | 98 | 0.175 | | +| [test-text.R](https://github.com/jonocarroll/ggeasy/blob/r_devel_env_check/tests/testthat/test-text.R#L220) | text alignment | easy\_center\_title works | PASS | 1 | 0.023 | | | Failed | Warning | Skipped | -| :----- | :------ | :------ | +|:-------|:--------|:--------| | ๐Ÿ›‘ | โš ๏ธ | ๐Ÿ”ถ |
-
- - Session Info + +Session Info + | Field | Value | -| :------- | :---------------------------- | -| Version | R version 3.5.2 (2018-12-20) | +|:---------|:------------------------------| +| Version | R version 4.0.3 (2020-10-10) | | Platform | x86\_64-pc-linux-gnu (64-bit) | -| Running | Pop\!\_OS 19.04 | +| Running | Pop!\_OS 20.10 | | Language | en\_AU | | Timezone | Australia/Adelaide | | Package | Version | -| :------- | :------ | -| testthat | 2.2.1 | -| covr | 3.3.1 | -| covrpage | 0.0.70 | +|:---------|:--------| +| testthat | 3.0.1 | +| covr | 3.5.1 | +| covrpage | 0.1 |
- diff --git a/vignettes/tests_and_coverage.html b/vignettes/tests_and_coverage.html deleted file mode 100644 index 273d0a0..0000000 --- a/vignettes/tests_and_coverage.html +++ /dev/null @@ -1,845 +0,0 @@ - - - - - - - - - - - - - - - -Tests and Coverage - - - - - - - - - - - - - - - - - - -

Tests and Coverage

-

19 January, 2020 09:42:20

- - - - -

This output is created by covrpage.

-
-

Coverage

-

Coverage summary is created using the covr package.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ObjectCoverage (%)
ggeasy100
R/axis.R100
R/labs.R100
R/labs2.R100
R/legend.R100
R/text.R100
-


-
-
-

Unit Tests

-

Unit Test summary is created using the testthat package.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
filentimeerrorfailedskippedwarningicon
test-labs.R101.2270040๐Ÿ”ถ
test-legend.R860.6380000
test-remove-axis.R200.2380000
test-rotate.R230.1980000
test-text.R610.5860000
-
-

Show Detailed Test Results

- --------- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
filecontextteststatusntimeicon
test-labs.Rattr labseasy_labs uses column attribSKIPPED40.338๐Ÿ”ถ
test-labs.Rattr labsregular labs overides easy_labsSKIPPED20.435๐Ÿ”ถ
test-labs.Rattr labsregular labs pass new labels through easy_labsSKIPPED20.222๐Ÿ”ถ
test-labs.Rattr labscolumn name used when no column attrib presentSKIPPED20.232๐Ÿ”ถ
test-legend.Rremove legendeasy_remove_legend works with no argumentPASS10.013
test-legend.Rremove legendeasy_remove_legend works with single character argumentPASS10.011
test-legend.Rremove legendeasy_remove_legend works with single bare argumentPASS10.015
test-legend.Rremove legendeasy_remove_legend works with multiple character argumentsPASS10.016
test-legend.Rremove legendeasy_remove_legend works with multiple bare argumentsPASS10.023
test-legend.Rremove legendeasy_remove_legend teach = TRUE works with no other argumentsPASS20.005
test-legend.Rremove legendeasy_remove_legend teach = TRUE works with specific aesPASS20.005
test-legend.Rremove legendeasy_remove_legend teach = TRUE works with multiple aesPASS20.004
test-legend.Rmove legendeasy_change_legend errors with no argumentPASS10.001
test-legend.Rmove legendeasy_change_legend works with combinationsPASS40.061
test-legend.Rmove legendeasy_move_legend works with no argumentPASS10.022
test-legend.Rmove legendeasy_move_legend works with specified argumentPASS30.040
test-legend.Rmove legendeasy_move_legend errors with bad argumentPASS10.001
test-legend.Rmove legendeasy_move_legend aliases workPASS30.046
test-legend.Rmove legendeasy_move_legend teach = TRUE works with combinationsPASS40.022
test-legend.Rmove legendeasy_legend_at teach = TRUE works with combinationsPASS40.021
test-legend.Rmove legendeasy_change_legend teach = TRUE works with positionPASS30.017
test-legend.Rlegend directioneasy_rotate_legend works with no argumentPASS10.013
test-legend.Rlegend directioneasy_rotate_legend works with combinationsPASS40.062
test-legend.Rlegend directioneasy_rotate_legend teach = TRUE works with combinationsPASS40.020
test-legend.Rlegend justificationeasy_adjust_legend works with no argumentPASS10.016
test-legend.Rlegend justificationeasy_adjust_legend works with combinationsPASS30.054
test-legend.Rlegend justificationeasy_adjust_legend errors with bad argumentPASS10.001
test-legend.Rlegend justificationeasy_adjust_legend teach = TRUE works with justificationPASS30.019
test-legend.Rlegend justificationeasy_change_legend teach = TRUE works with justificationPASS30.018
test-legend.Rlegend justificationeasy_rotate_legend teach = TRUE works with combinationsPASS40.019
test-legend.Rlegend titleeasy_add_legend_title errors with no argumentPASS10.001
test-legend.Rlegend titleeasy_add_legend_title relabels a single legend titlePASS10.032
test-legend.Rlegend titleeasy_add_legend_title relabels all legend titlesPASS90.020
test-legend.Rlegend titleeasy_add_legend_title teach = TRUE works with specific aesPASS40.017
test-legend.Rlegend titleeasy_add_legend_title teach = TRUE works with unspecific aesPASS120.023
test-remove-axis.Rremove axesno argumentPASS30.056
test-remove-axis.Rremove axesexplicit axisPASS100.117
test-remove-axis.Rremove axesmultiple componentsPASS40.054
test-remove-axis.Rremove axesteach argument produces working codePASS30.011
test-rotate.Rrotate labelsrotation of both labelsPASS170.109
test-rotate.Rrotate labelsrotation of x labelsPASS30.039
test-rotate.Rrotate labelsrotation of y labelsPASS30.050
test-text.Radjust text sizesset text sizesPASS430.387
test-text.Radjust text colorsset text colorsPASS180.199
- - - - - - - - - - - - - - - -
FailedWarningSkipped
๐Ÿ›‘โš ๏ธ๐Ÿ”ถ
-
-
-

Session Info

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FieldValue
VersionR version 3.5.2 (2018-12-20)
Platformx86_64-pc-linux-gnu (64-bit)
RunningPop!_OS 19.04
Languageen_AU
TimezoneAustralia/Adelaide
- - - - - - - - - - - - - - - - - - - - - -
PackageVersion
testthat2.2.1
covr3.3.1
covrpage0.0.70
-
- -
- - - - - - - - - - -