Learn R Programming

wyz.code.metaTesting (version 1.1.22)

opwf: Offensive Programming Wrap Function

Description

Create an offensive programming function, wrapping a standard R function.

Usage

opwf(fun_f_1, parameterNames_s, functionName_s_1 = NA_character_)

Value

A R

function which takes given parameterNames_s as arguments.

Arguments

fun_f_1

a single R function

parameterNames_s

the new names of the parameter function, must be semantic argument names. Must be a bijection to actual fun_f_1 argument names.

functionName_s_1

A string holding the function name. Default value, implies evaluation using deparse(substitute(fun_f_1))

Author

tools:::Rd_package_author("wyz.code.metaTesting")

Maintainer: tools:::Rd_package_maintainer("wyz.code.metaTesting")

Details

If any arguments default values are present, they are managed transparently and should be correctly and automatically substituted.

See Also

Refer to testFunction

Examples

Run this code
# typical example
op_sum <- opwf(sum, c('...', 'removeNA_b_1'))

# example with substituted argument in existing default valued arguments
op_append <- opwf(append, c('originalValues_', 'valuesToInsert_', 'afterIndex_ui_1'))

Run the code above in your browser using DataLab