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

[internal] Prepare internal reporting #143

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

yoannmoinet
Copy link
Member

What and why?

Splitting out from #134 to simplify the reviewing process.

How?

A bunch of small fixes and updates, especially in testing.

  1. Now support --silent flag from Jest and turn it on for CI.
  2. A bunch of factorisation:
    a. Context creation to avoid duplication of data necessary every time we change the context.
    b. Mock async-rety for all the test to reduce its timeouts and run faster.
  3. Create an environment variable.
    a. $BUILD_PLUGINS_ENV which can be production, development and test.
    b. Share it on context.env.
    c. Add typings for process.env in global.d.ts.
  4. Add more options to the doRequest helper.
    a. retries for the max number of retries.
    b. minTimeout for the how long to wait between retries.
    c. maxTimeout for the maximum amount of time to wait after a few retries (x2 each time).
    d. Reduce impact of the injection's fetch on the build by reducing it to 2 reties and minTimeout of 100.
  5. Upgrade of nock.
  6. Greatly simplify the runBundlers helper, so it auto cleans up at the end.
  7. Greatly optimise the injection tests, from ~40s down to ~10s.

@yoannmoinet yoannmoinet marked this pull request as ready for review February 21, 2025 15:16
@yoannmoinet yoannmoinet requested review from elbywan and Miz85 February 21, 2025 15:16
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