public static final class IntegTestCase.Builder
extends java.lang.Object
IntegTestCase
.Modifier and Type | Method and Description |
---|---|
IntegTestCase.Builder |
allowDestroy(java.util.List<java.lang.String> allowDestroy)
List of CloudFormation resource types in this stack that can be destroyed as part of an update without failing the test.
|
IntegTestCase |
build() |
IntegTestCase.Builder |
cdkCommandOptions(CdkCommands cdkCommandOptions)
Additional options to use for each CDK command.
|
static IntegTestCase.Builder |
create(software.constructs.Construct scope,
java.lang.String id) |
IntegTestCase.Builder |
diffAssets(java.lang.Boolean diffAssets)
Whether or not to include asset hashes in the diff Asset hashes can introduces a lot of unneccessary noise into tests, but there are some cases where asset hashes _should_ be included.
|
IntegTestCase.Builder |
hooks(Hooks hooks)
Additional commands to run at predefined points in the test workflow.
|
IntegTestCase.Builder |
regions(java.util.List<java.lang.String> regions)
Limit deployment to these regions.
|
IntegTestCase.Builder |
stacks(java.util.List<? extends Stack> stacks)
(experimental) Stacks to be deployed during the test.
|
IntegTestCase.Builder |
stackUpdateWorkflow(java.lang.Boolean stackUpdateWorkflow)
Run update workflow on this test case This should only be set to false to test scenarios that are not possible to test as part of the update workflow.
|
public static IntegTestCase.Builder create(software.constructs.Construct scope, java.lang.String id)
scope
- This parameter is required.id
- This parameter is required.IntegTestCase.Builder
.public IntegTestCase.Builder allowDestroy(java.util.List<java.lang.String> allowDestroy)
This list should only include resources that for this specific integration test we are sure will not cause errors or an outage if destroyed. For example, maybe we know that a new resource will be created first before the old resource is destroyed which prevents any outage.
e.g. ['AWS::IAM::Role']
Default: - do not allow destruction of any resources on update
allowDestroy
- List of CloudFormation resource types in this stack that can be destroyed as part of an update without failing the test. This parameter is required.this
public IntegTestCase.Builder cdkCommandOptions(CdkCommands cdkCommandOptions)
Default: - runner default options
cdkCommandOptions
- Additional options to use for each CDK command. This parameter is required.this
public IntegTestCase.Builder diffAssets(java.lang.Boolean diffAssets)
For example any tests involving custom resources or bundling
Default: false
diffAssets
- Whether or not to include asset hashes in the diff Asset hashes can introduces a lot of unneccessary noise into tests, but there are some cases where asset hashes _should_ be included. This parameter is required.this
public IntegTestCase.Builder hooks(Hooks hooks)
e.g. { postDeploy: ['yarn', 'test'] }
Default: - no hooks
hooks
- Additional commands to run at predefined points in the test workflow. This parameter is required.this
public IntegTestCase.Builder regions(java.util.List<java.lang.String> regions)
Default: - can run in any region
regions
- Limit deployment to these regions. This parameter is required.this
public IntegTestCase.Builder stackUpdateWorkflow(java.lang.Boolean stackUpdateWorkflow)
Default: true
stackUpdateWorkflow
- Run update workflow on this test case This should only be set to false to test scenarios that are not possible to test as part of the update workflow. This parameter is required.this
public IntegTestCase.Builder stacks(java.util.List<? extends Stack> stacks)
stacks
- Stacks to be deployed during the test. This parameter is required.this
public IntegTestCase build()