Skip to content

AssertProps

Properties for defining a Assert.

See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-ros-assert

Initializer

import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkros"
&alicloudroscdkros.AssertProps {
    Values: interface{},
    AbortCreation: interface{},
    ErrorMessage: interface{},
    Operation: interface{},
}

Properties

Name Type Description
Values interface{} Property values: A list of values to assert.
AbortCreation interface{} Property abortCreation: Whether to abort creation when the assert fails.
ErrorMessage interface{} Property errorMessage: The error message to be returned when the assert fails.
Operation interface{} Property operation: The type of assertion to make.

ValuesRequired

Values interface{}
  • Type: interface{}

Property values: A list of values to assert.

The items in the list are compared in order. The range of length is one to three.

  • Three values are supported only if the operation is Equal or NotEqual.
  • One value is supported only if the operation is Not.

AbortCreationOptional

AbortCreation interface{}
  • Type: interface{}

Property abortCreation: Whether to abort creation when the assert fails.

Default is True.


ErrorMessageOptional

ErrorMessage interface{}
  • Type: interface{}

Property errorMessage: The error message to be returned when the assert fails.


OperationOptional

Operation interface{}
  • Type: interface{}

Property operation: The type of assertion to make.

The supported operations are: Equal, NotEqual, Greater, GreaterOrEqual, Less, LessOrEqual, Contain, NotContain, And, Or, Not. Default is Equal.