integ-tests: add customer focused documentation on using integration tests
- Dominant language
- TypeScript
- Stars
- 12.9k
- Forks
- 4.6k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 83
Description
### Describe the bug
We choose to not use the default bootstrap qualifier name (`hnb659fds`), and instead rename it `default`. For our CDK apps this works fine, as we can just update the `cdk.json` file and be done. However, we have noticed that the Integration Tests (`integ-tests-alpha` and `integ-runner` modules) do not honor either the `cdk.json` file OR passing in a custom Synthesizer option.
See Slack Thread: https://cdk-dev.slack.com/archives/C018XT6REKT/p1667598499102579
### Expected Behavior
I would expect that both the `cdk.json` and the custom synthesizer would be honored, but neither seem to be.
### Current Behavior
You seem to be stuck using the default bootstrap qualifier name, and that's a shame.
### Reproduction Steps
Example Code:
```typescript
const app = new App();
const stack = new Stack(app, "root", {
env: env,
synthesizer: new DefaultStackSynthesizer({
qualifier: "default",
}),
});
new NestedVpcStack(stack, "vpc", {});
new IntegTest(app, "IntegTest", {
testCases: [stack],
});
```
Output:
```
✨ Synthesis time: 0.52s
IntegTest/DefaultTest/DeployAssert: building assets...
current credentials could not be used to assume 'arn:aws:iam::xxxxx:role/cdk-hnb659fds-deploy-role-xxxx-us-west-2', but are for the right account. Proceeding anyway.
root: building assets...
[0%] start: Building 38c0da6d553db6d234152b663483ada66ada1d1c171ca6453fc401569f821b28:xxxx-us-west-2
```
### Possible Solution
_No response_
### Additional Information/Context
_No response_
### CDK CLI Version
2.50.0
### Framework Version
_No response_
### Node.js Version
18.9.0
### OS
Mac OSX
### Language
Typescript
### Language Version
typescript 4.8.4
### Other information
_No response_
Contributor guide
Research direction
The report points to the integ-tests-alpha and integ-runner modules and includes a TypeScript IntegTest reproduction using DefaultStackSynthesizer. Start by reviewing how integration tests handle cdk.json and custom synthesizers, then determine what customer guidance is needed for the bootstrap qualifier behavior. Done means the documentation covers the shown setup and its expected behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- documentation, testing
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 28/100