You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+104Lines changed: 104 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -332,6 +332,110 @@ $ cd packages/aws-cdk
332
332
$ yarn watch &# runs in the background
333
333
```
334
334
335
+
#### Verify your fix by deployment
336
+
337
+
If your PR updates a specific library, you might want to write a simple CDK application and make sure it synthesizes and
338
+
deploys correctly. For example, if you modify files under `packages/aws-cdk-lib/aws-eks`, you can write a simple CDK app in typescript to verify its behavior:
339
+
340
+
341
+
```console
342
+
$ cd packages/@aws-cdk-testing/framework-integ/test/aws-eks/test
Run `yarn watch` or `npx tsc --watch` in a separate terminal to compile `sample.ts` to `sample.js`:
367
+
368
+
```console
369
+
$ cd packages/@aws-cdk-testing/framework-integ
370
+
$ yarn watch
371
+
or
372
+
$ npx tsc --watch
373
+
```
374
+
375
+
Make sure you have configured [AWS CLI with AWS Authentication](https://docs.aws.amazon.com/cdk/v2/guide/getting_started.html#getting_started_auth) as we will deploy it in our AWS account.
376
+
377
+
Deploy the sample app:
378
+
379
+
```console
380
+
$ cd packages/@aws-cdk-testing/framework-integ
381
+
$ npx cdk -a test/aws-eks/test/sample.js diff
382
+
$ npx cdk -a test/aws-eks/test/sample.js deploy
383
+
```
384
+
385
+
This allows you to iterate your development and ensure a minimal sample app would successfully deploy as you expect.
386
+
You have the freedom to interact with it just as a common CDK app such as viewing differences with `npx cdk diff`
387
+
or pass context variables with `npx cdk deploy -c`. You can rapidly iterate your testing with repeated deployments
388
+
by importing existing resource such as existing VPC. This can save a lot of time and help you focus on the core changes.
0 commit comments