EqualsAssertion

class aws_cdk.integ_tests.EqualsAssertion(scope, id, *, actual, expected, fail_deployment=None)

Bases: Construct

(experimental) Construct that creates a CustomResource to assert that two values are equal.

Stability:

experimental

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.integ_tests as integ_tests

# actual_result: integ_tests.ActualResult
# expected_result: integ_tests.ExpectedResult

equals_assertion = integ_tests.EqualsAssertion(self, "MyEqualsAssertion",
    actual=actual_result,
    expected=expected_result,

    # the properties below are optional
    fail_deployment=False
)
Parameters:
  • scope (Construct) –

  • id (str) –

  • actual (ActualResult) – (experimental) The actual results to compare.

  • expected (ExpectedResult) – (experimental) The expected result to assert.

  • fail_deployment (Optional[bool]) – (experimental) Set this to true if a failed assertion should result in a CloudFormation deployment failure. This is only necessary if assertions are being executed outside of integ-runner. Default: false

Stability:

experimental

Methods

to_string()

Returns a string representation of this construct.

Return type:

str

Attributes

node

The construct tree node associated with this construct.

result

(experimental) The result of the assertion.

Stability:

experimental

Static Methods

classmethod is_construct(x)

Return whether the given object is a Construct.

Parameters:

x (Any) –

Return type:

bool