Commit 362c8173 authored by Dorchies David's avatar Dorchies David
Browse files

ci: Run tests on patched, devel and oldrel versions of R

- Different version of R have been compiled in `~/R/R-${R_VERSION}`
- push tests are executed on patched version
- oldrel and devel versions are tested on scheduled and tag pipelines

Refs #55
Showing with 77 additions and 9 deletions
+77 -9
......@@ -2,26 +2,94 @@ stages:
- build
- tests
build:
default:
before_script:
- echo "setwd(\"$(pwd)\")" > .Rprofile
.build:
stage: build
script:
- cd ..
- echo "setwd(\"$(pwd)\")" > .Rprofile
- R CMD build airgr
- ~/R/R-${R_VERSION}/bin/R CMD build airgr
- mv *.tar.gz airgr/
artifacts:
untracked: true
expire_in: 1 week
check_not_cran:
.check_not_cran:
stage: tests
variables:
NOT_CRAN: "true"
script:
- echo "setwd(\"$(pwd)\")" > .Rprofile
- echo "Sys.setenv(NOT_CRAN = \"true\")" >> .Rprofile
- R CMD check airGR_*.tar.gz
- ~/R/R-${R_VERSION}/bin/R CMD check airGR_*.tar.gz
check_as_cran:
.check_as_cran:
stage: tests
script:
- echo "setwd(\"$(pwd)\")" > .Rprofile
- R CMD check --as-cran airGR_*.tar.gz
- ~/R/R-${R_VERSION}/bin/R CMD check --as-cran airGR_*.tar.gz
build_patched:
variables:
R_VERSION: "patched"
extends: .build
check_not_cran_patched:
variables:
R_VERSION: "patched"
extends: .check_not_cran
check_as_cran_patched:
variables:
R_VERSION: "patched"
extends: .check_as_cran
build_devel:
only:
refs:
- tags
- schedules
variables:
R_VERSION: "devel"
extends: .build
check_not_cran_devel:
refs:
- tags
- schedules
variables:
R_VERSION: "devel"
extends: .check_not_cran
check_as_cran_devel:
refs:
- tags
- schedules
variables:
R_VERSION: "devel"
extends: .check_as_cran
build_oldrel:
only:
refs:
- tags
- schedules
variables:
R_VERSION: "oldrel"
extends: .build
check_not_cran_oldrel:
refs:
- tags
- schedules
variables:
R_VERSION: "oldrel"
extends: .check_not_cran
check_as_cran_oldrel:
refs:
- tags
- schedules
variables:
R_VERSION: "oldrel"
extends: .check_as_cran
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment