Utility functions

Share:

Description

Utility functions

Utility for testing how a function deals with missing required arguments. It calls the function length(args) times, each time omitting one argument

Usage

1
missing_argument_test(fun, args, outcomes)

Arguments

fun

Function to test

args

Complete list of required arguments to fun

outcomes

List of length args with expected outcomes for each test. Names should match those of args. Values should be either "FAIL", if the test is expected to throw an error, or anything else if it is expected to pass.

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.