Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

End-to-end build + CDK testing #318

Merged
merged 8 commits into from
Jul 25, 2024
Merged

End-to-end build + CDK testing #318

merged 8 commits into from
Jul 25, 2024

Conversation

twelch
Copy link
Contributor

@twelch twelch commented Jul 23, 2024

Part of #288

  • adds back testing of a variety of gp project scenarios from empty to one with full set of functions and clients.
  • adds support for asserting nested LambdaStacks
  • saves snapshot of all test stacks, but doesn't match them or keep them in the repo anymore. Only used for developer inspection now.
  • instead of simply creating in-memory project assets to generate a manifest, uses new createTestBuild function which generates a test project with assets on disk and builds their functions and clients into .build and .build-web directories. It's a little slow with all the I/O and running of esbuild and Vite. This was the simplest way to produce assets in the form and location that CDK expects. The added benefit is the build process now has solid test coverage, and with the cdk test provides more thorough end-to-end testing.

@twelch twelch changed the base branch from dev to scale-lambda-stacks July 23, 2024 22:53
@twelch twelch marked this pull request as ready for review July 25, 2024 05:05
@twelch twelch changed the title Add back end-to-end snapshot testing with added project build End-to-end build + CDK testing Jul 25, 2024
@twelch twelch merged commit 05937f6 into scale-lambda-stacks Jul 25, 2024
2 checks passed
@twelch twelch deleted the vitest-stack branch July 25, 2024 05:27
twelch added a commit that referenced this pull request Jul 25, 2024
#314)

* switch to scalable LambdaStack creation function, rename functions to projectFunctions

* cleanup

* refactor metrics splitting to use minimum number of db items

* refactor metrics splitting to use minimum number of db items (#317)

* add epoch timestamp to lambda function logical IDs to avoid duplication name collision on reconstructive deploys

* drop timestamp from logical IDs

* export byteSize helper

* move policy creation back into lambda stack, and keep run lambda agg in parent stack

* End-to-end build + CDK testing (#318)

* stub createTestBuild, refactor our buildProjectFunctions

* improve createTestBuild, add back preprocessor stack test and remove snapshot dir

* fix gitignore bug

* refactor out clientBuild, add back StackEmpty and StackC

* add back StackAG

* add StackSG, explicitly set executionMode in functions

* Add StackAll test

* drop logging

---------

Co-authored-by: Abby Vath Meyer <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant