forked from bwlewis/rredis
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add support for Travis checks from GitHub
- Loading branch information
1 parent
17d4254
commit 66ca350
Showing
10 changed files
with
76 additions
and
8 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Sample .travis.yml for R projects. | ||
# | ||
# See the r-travis repo and its wiki | ||
# https://github.com/craigcitro/r-travis/wiki | ||
# https://github.com/eddelbuettel/r-travis/ | ||
|
||
language: c | ||
|
||
env: | ||
global: | ||
- _R_CHECK_FORCE_SUGGESTS_=FALSE | ||
- RunRRedisTests=yes | ||
|
||
before_install: | ||
- curl -OL http://raw.github.com/craigcitro/r-travis/master/scripts/travis-tool.sh | ||
- chmod 755 ./travis-tool.sh | ||
- ./travis-tool.sh bootstrap | ||
|
||
install: | ||
- ./travis-tool.sh install_aptget redis-server | ||
|
||
script: | ||
- ./travis-tool.sh run_tests | ||
|
||
after_failure: | ||
- ./travis-tool.sh dump_logs | ||
|
||
notifications: | ||
email: | ||
on_success: change | ||
on_failure: change | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,11 @@ | ||
Package: rredis | ||
Type: Package | ||
Title: Redis client for R | ||
Version: 1.6.8.1 | ||
Version: 1.6.8.2 | ||
Date: 2014-01-05 | ||
Author: B. W. Lewis | ||
Maintainer: B. W. Lewis <blewis@illposed.net> | ||
Description: An R client for the Redis persistent key-value database available from http://redis.io. | ||
License: Apache License (>= 2.0) | ||
LazyLoad: yes | ||
Suggests: RUnit |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
|
||
## doRUnit.R --- Run RUnit tests | ||
## | ||
## with credits to package fUtilities in RMetrics | ||
## which credits Gregor Gojanc's example in CRAN package 'gdata' | ||
## as per the R Wiki http://wiki.r-project.org/rwiki/doku.php?id=developers:runit | ||
## and changed further by Martin Maechler | ||
## and more changes by Murray Stokely in HistogramTools | ||
## | ||
## Dirk Eddelbuettel, Jan 2014 | ||
|
||
stopifnot(require(RUnit, quietly=TRUE)) | ||
stopifnot(require(rredis, quietly=TRUE)) | ||
|
||
## Set a seed to make the test deterministic | ||
set.seed(42) | ||
|
||
## Define tests | ||
testSuite <- defineTestSuite(name="rredis Unit Tests", | ||
dirs=system.file("test", package="rredis"), | ||
testFuncRegexp = "^[Tt]est+") | ||
|
||
## rredis requires a redis server | ||
## we cannot always assume one, so default to FALSE | ||
runTests <- FALSE | ||
|
||
## if we a redis server is set up, we can sigmal this | ||
if (Sys.getenv("RunRRedisTests")=="yes") runTests <- TRUE | ||
|
||
## Tests for test run | ||
if (runTests) { | ||
## Run tests | ||
tests <- runTestSuite(testSuite) | ||
|
||
## Print results | ||
printTextProtocol(tests) | ||
|
||
## Return success or failure to R CMD CHECK | ||
if (getErrors(tests)$nFail > 0) { | ||
stop("TEST FAILED!") | ||
} | ||
} |