-
Notifications
You must be signed in to change notification settings - Fork 1k
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
rw test api
Jest memory performance and benchmarks; api test leaking
#4360
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Background
Originally reported by @zygopleural here:
Web memory leak resolved and API memory leak mitigated via:
Because the API memory leak is not fully resolved, we want to benchmark and watch performance as well as keep this issue open for further work toward complete resolution.
This Issue uses the original reproduction with the new benchmarks.
related benchmark issue #4356
Expected behaviour
yarn redwood test
should use ~ same heap size for each test unless the user has specifically done something wrong.i.e. the heap size should not increase with each consecutive test or run (i.e. leak)
What currently happens
rw test web
:The heap size is stable
rw test api
:Even after mitigation in #4096 the heap size increases along with quantity of tests
Steps to reproduce
Option 1: Clone the Reproduction Repo
Option 2. Create new app and run commands
1. Creat App
yarn create redwood-app --typescript test
2. Add some models to
./api/db/schema.prisma
Excuse the silly models, just something quick to generate tests.
3. Generate some tests
4. Run tests
yarn redwood test --logHeapUsage
Benchmarks as of v0.44
Initial test (watch mode)
Second Run (watch
mode)
Third Run (watch mode)
The text was updated successfully, but these errors were encountered: