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

Add afterEach hook #31

Open
RafaelGSS opened this issue Dec 16, 2024 · 0 comments · May be fixed by #35
Open

Add afterEach hook #31

RafaelGSS opened this issue Dec 16, 2024 · 0 comments · May be fixed by #35

Comments

@RafaelGSS
Copy link
Owner

So users would be able to write benchmarks like:

bench
  .add(
    'Import with node: prefix',
    { afterEach:  () => { delete import.meta.cache } },
    () => {
      return import('node:fs');
    }
  )
  .add(
    'Import without node: prefix',
    { afterEach:  () => { delete import.meta.cache } },
    () => {
      return import('fs');
   }
  );
RafaelGSS added a commit that referenced this issue Dec 30, 2024
RafaelGSS added a commit that referenced this issue Dec 30, 2024
@RafaelGSS RafaelGSS linked a pull request Dec 30, 2024 that will close this issue
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 a pull request may close this issue.

1 participant