Skip to content

Commit 2c0b14c

Browse files
committed
ci: refactor r tests, from 8 to 5 (~15 min saved)
1 parent f8d0efe commit 2c0b14c

File tree

33 files changed

+27
-43
lines changed

33 files changed

+27
-43
lines changed

repo2docker/buildpacks/r.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ def r_version(self):
7979
#
8080
# NOTE: When updating this version, also update
8181
# - tests/unit/test_r.py -> test_version_specification
82-
# - tests/r/simple/verify
82+
# - tests/r/r-rspm-apt/verify
8383
#
8484
r_version = version_map["4.2"]
8585

tests/r/apt/install.R

Lines changed: 0 additions & 1 deletion
This file was deleted.

tests/r/apt/runtime.txt

Lines changed: 0 additions & 1 deletion
This file was deleted.

tests/r/mran/install.R

Lines changed: 0 additions & 1 deletion
This file was deleted.
File renamed without changes.
File renamed without changes.

tests/r/r-rspm-apt/install.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
install.packages("digest")

tests/r/r-rspm-apt/runtime.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
r-2022-06-23

tests/r/r-rspm-apt/verify

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
4+
./verify.sh
5+
./verify.r
Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
#!/usr/bin/env Rscript
2-
library('testthat')
2+
library('digest')
33

4-
# Fail if version is not 4.2
4+
5+
# Fail if version isn't 4.2, the default version for the RBuildPack
6+
print(version)
57
if (!(version$major == "4" && as.double(version$minor) >= 2 && as.double(version$minor) < 3)) {
68
quit("yes", 1)
7-
}
9+
}

0 commit comments

Comments
 (0)