Expose state/functionality in ParameterizeScope
, instead of just from configuration handlers
#25
Labels
enhancement
New feature or request
Currently, some of parameterize's functionality is only available from within the configuration hooks, which is very restrictive. All the functionality available with the configuration could be exposed, allowing it to be extensible and used more flexibly.
To avoid namespace pollution in the
parameterize {}
block, this functionality should be hidden behind a property in the scope. For example, inspired by coroutineContext in the stdlib, this could look something likeparameterizeContext.isFirstIteration
.decorator
isFirstIteration
isLastIteration
iteration()
lambda is called. That can't be matched if generalized to use in the block, because the runtime can't know when the "iteration" code is donefalse
onFailure
iterationCount
failureCount
arguments
ParameterDelegate
s, withproperty
andargument
declaredcParameters
(and maybe also renamingParameterDelegate
toDeclaredParameter
)breakEarly
recordFailure
ParameterizeFailure
so devs can keep track of them on their ownonComplete
iterationCount
failureCount
completedEarly
recordedFailures
ParameterizeFailedError
constructorThe text was updated successfully, but these errors were encountered: