Completed working test suite and added CI

This commit is contained in:
pegeler 2018-06-28 17:20:14 -04:00
commit a0a482abef
10 changed files with 153 additions and 55 deletions

View file

@ -1,22 +1,16 @@
context("Reading in JSON")
# Set up the path ----------------------------------------------------------
data_dir <- system.file("tests", "testthat", "data", package = "REDCapRITS")
# Check the RCurl export ---------------------------------------------------
test_that("JSON character vector from RCurl matches reference", {
metadata <- jsonlite::fromJSON(
file.path(
data_dir,
get_data_location(
"ExampleProject_metadata.json"
)
)
records <- jsonlite::fromJSON(
file.path(
data_dir,
get_data_location(
"ExampleProject_records.json"
)
)