CurveSingleExpectation

class CurveSingleExpectation

Represents a sparse curve of expectations. Each element of the curve represents an individual expectation on the respective value. All individual expectations must be fulfilled in order for the this curve expectation to be fulfilled.

Each individual expectation is specified as a Boolean expression in Python syntax. The special identifier “value” refers to the actual value of the curve element.

Returned by

Clone()

Call this method if you want to use API-objects in multiple contexts, e.g. if you want to insert a specific test step in multiple blocks.

Returns:

A copy of this object

Return type:

CurveSingleExpectation

GetDimension()

Returns the dimension of the element.

Returns:

Dimension of the element.

Return type:

int

GetDistributionExpectation(index)

Gets the distribution level of the given position.

Parameters:
index : int

Index of the expectation object.

Returns:

Distribution level expectation object

Return type:

Expectation

GetDistributionExpectationExpression(index)

Gets the distribution level of the given position.

Parameters:
index : int

index

Returns:

Distribution level expectation expression

Return type:

str

GetDistributionExpectationExpressions()

Returns a list of all distribution level expectation expression. Elements without expectation are represented by None

Returns:

Sorted list containing all distribution level expectation expressions

Return type:

list[str]

GetExpectation(index)

Returns the expectation object for the specified element.

Parameters:
index : int

Index of the expectation object.

Returns:

The expectation object

Return type:

Expectation

GetExpectationExpression(index)

Returns the expectation expression for the specified element.

Parameters:
index : int

Index of the expression.

Returns:

The expression

Return type:

str

GetExpectationExpressions()

Returns a list of all expectation expression. Elements without expectation are represented by None

Returns:

Sorted list containing all expectation expressions

Return type:

list[str]

RemoveDistributionExpectation(index)

Deletes the distribution level of the given position.

Parameters:
index : int

index

RemoveExpectation(index)

Removes the expectation expression for the specified element.

Parameters:
index : int

Index of the expression to remove.

SetDistributionExpectation(index, expectationObject)

Sets the distribution level of the given position.

Parameters:
index : int

Index of the expectation object.

expectationObject

Distribution level expectation object

SetDistributionExpectationExpression(index, expression)

Sets the distribution level of the given position.

Parameters:
index : int

index

expression : str

Distribution level expectation expression

SetExpectation(index, expectationObject)

Sets the expectation object for the specified element.

Parameters:
index : int

Index of the expectation object.

expectationObject

The expectation object

SetExpectationExpression(index, expression)

Sets the expectation expression for the specified element.

Parameters:
index : int

Index of the expression.

expression : str

The expression