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

Move from test-unit to spec #384

Merged
merged 1 commit into from Jun 10, 2023

Conversation

triallax
Copy link
Collaborator

The migration is rather straightforward, but it brings a HUGE decrease in the time required to run tests as determined by hyperfine --warmup 2 'npm test'. Before:

Benchmark 1: npm test
  Time (mean ± σ):     71.245 s ±  0.619 s    [User: 75.323 s, System: 0.868 s]
  Range (min … max):   70.245 s … 72.363 s    10 runs

After:

Benchmark 1: npm test
  Time (mean ± σ):     18.666 s ±  0.256 s    [User: 22.082 s, System: 0.671 s]
  Range (min … max):   18.327 s … 19.048 s    10 runs

I'm also considering moving to assert instead, but it's much lower-level than the other two, so I'm not too sure about that. It could be worth a try though.

@triallax triallax changed the title Move to from test-unit to spec Move from test-unit to spec May 28, 2023
test/Main.purs Outdated Show resolved Hide resolved
The migration is rather straightforward, but it brings a HUGE decrease
in the time required to run tests as determined by
`hyperfine --warmup 2 'npm test'`. Before:

Benchmark 1: npm test
  Time (mean ± σ):     71.245 s ±  0.619 s    [User: 75.323 s, System: 0.868 s]
  Range (min … max):   70.245 s … 72.363 s    10 runs

After:

Benchmark 1: npm test
  Time (mean ± σ):     18.666 s ±  0.256 s    [User: 22.082 s, System: 0.671 s]
  Range (min … max):   18.327 s … 19.048 s    10 runs
@triallax triallax merged commit 5e4f34f into sharkdp:master Jun 10, 2023
1 check passed
@sharkdp
Copy link
Owner

sharkdp commented Jun 12, 2023

This is awesome, thank you very much

@triallax triallax deleted the move-to-purescript-spec branch June 13, 2023 10:37
@triallax
Copy link
Collaborator Author

@sharkdp you're welcome.

I'm trying to merge "uncontroversial" PRs on my own initiative instead of waiting for your review. I hope that's fine with you?

@sharkdp
Copy link
Owner

sharkdp commented Jun 13, 2023

Yes, that is completely fine

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.

None yet

2 participants