% Generated by roxygen2 (4.1.0): do not edit by hand
% Please edit documentation in R/testr.r
\name{customGenerator}
\alias{customGenerator}
\title{Creates new custom generator.

A generator is identified by its content function which is called with the index of the value, the generator itself and already evaluated generators. The generator also must have assigned a name.

 Generators can be dependent or independent. Independent generators define how many tests a single test definition will be expanded to since for each possible permutation of independent generator values a new test is produced.}
\usage{
customGenerator(name, contentFunction, ..., dependsOn = NULL, length = 1)
}
\arguments{
\item{name}{Name of the generic - either string or an unquoted name}

\item{contentFunction}{Function that provides the content of the generator.}

\item{...}{any other optional named arguments that will become fields of the returned generator S3 object. These additional arguments are not evaluated and are stored as their language objects.}

\item{dependsOn}{Determines a generator on whose value this generator depends. That is if the generator the current one depends on changes, only then the dependent generator changes too.}

\item{length}{Number of values the generator provides, practically valid only for independent generators as dependent generators are simply evaluated as many times as the generator they depend on.}
}
\value{
The generator object that can be passed to the test function.
}
\description{
Creates new custom generator.

A generator is identified by its content function which is called with the index of the value, the generator itself and already evaluated generators. The generator also must have assigned a name.

 Generators can be dependent or independent. Independent generators define how many tests a single test definition will be expanded to since for each possible permutation of independent generator values a new test is produced.
}
\seealso{
is.generatorContentFunction, test
}

