run_validation_file: Run a file with confrontations. Capture results

Description Usage Arguments Value

View source: R/run_validation.R

Description

A validation script is a regular R script, intersperced with confront or check_that statements. This function will run the script file and capture all output from calls to these functions.

Usage

1
2
3
4
5
6
7
8
9
run_validation_file(file, verbose = TRUE)

run_validation_dir(dir = "./", pattern = "^validate.+[rR]", verbose = TRUE)

## S3 method for class 'validations'
print(x, ...)

## S3 method for class 'validations'
summary(object, ...)

Arguments

file

[character] location of an R file.

verbose

[logical] toggle verbose output.

dir

[character] path to directory.

pattern

[characer] regular expression that selects validation files to run.

x

An R object

...

Unused

object

An R object

Value

run_validation_file: An object of class validations. This is a list of objects of class validation.

run_validation_dir: An object of class validations. This is a list of objects of class validation.

print: NULL, invisibly.

summary: A data frame similar to the data frame returned when summarizing a validation object. There are extra columns listing each call, file and first and last line where the code occurred.


validate documentation built on Oct. 7, 2021, 9:19 a.m.