11
2- if (requireNamespace(" tinytest" , quietly = TRUE ) &&
3- utils :: packageVersion(" tinytest" ) > = " 1.0.0" ) {
2+ if (requireNamespace(" tinytest" , quietly = TRUE )) {
43
54 # # Set a seed to make the test deterministic
65 set.seed(42 )
76
8- # # R makes us to this
7+ # # R makes us do this (but tinytest now sets it too)
98 Sys.setenv(" R_TESTS" = " " )
109
1110 # # Force tests to be executed if in dev release which we define as
@@ -23,15 +22,20 @@ if (requireNamespace("tinytest", quietly=TRUE) &&
2322
2423 # # On Travis also always set tests; see
2524 # # https://docs.travis-ci.com/user/environment-variables/#default-environment-variables
26- if ((Sys.getenv(" CI" ) == " true" ) ||
27- (Sys.getenv(" TRAVIS" ) == " true" ) ||
28- (Sys.getenv(" CONTINUOUS_INTEGRATION" ) == " true" )) {
25+ # # GitHub Action also set CI variable; see
26+ # # https://docs.github.com/en/actions/reference/environment-variables
27+ # # (but we may not see these as we are in Docker)
28+ # # Ensure Codecov runs full tests too
29+ if ((Sys.getenv(" CI" ) == " true" ) ||
30+ (Sys.getenv(" TRAVIS" ) == " true" ) ||
31+ (Sys.getenv(" CONTINUOUS_INTEGRATION" ) == " true" ) ||
32+ (Sys.getenv(" CODECOV_TOKEN" ) != " " )) {
2933 if (Sys.getenv(" RunAllRcppTests" ) != " no" ) { # if env.var not yet set
30- message(" Always enabling \" RunAllRcppTests\" =\" yes\" on Travis \n " )
34+ message(" Always enabling \" RunAllRcppTests\" =\" yes\" in CI \n " )
3135 Sys.setenv(" RunAllRcppTests" = " yes" )
3236 }
3337 if (Sys.getenv(" RunVerboseRcppTests" ) != " no" ) { # if env.var not yet set
34- message(" Always enabling \" RunVerboseRcppTests\" =\" yes\" on Travis \n " )
38+ message(" Always enabling \" RunVerboseRcppTests\" =\" yes\" in CI \n " )
3539 Sys.setenv(" RunVerboseRcppTests" = " yes" )
3640 }
3741 }
0 commit comments