-
Notifications
You must be signed in to change notification settings - Fork 109
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 ability to supply options programmatically #414
Comments
Are existing mechanisms (such as There is also |
If this is about |
This breaks See #411 |
Lines 605 to 607 in 83b3a53
Instead of directly going for |
Hmm, should it not be other way around? ie. if |
No, |
Is That would be ideal for us because it would allow a sub-tree to be run single threaded allowing the rest to be concurrent. |
There are some other things I'm also interest in:
|
It should be possible to extend What's your use case? Usually when people want to execute tests sequentially, it's because they depend on the output of each other and that's why
There are
Could be implemented as newtypes with custom |
The use case is we're running integration tests in CI. Theoretically the tests are independent, however the code being tested is timing sensitive and in CI, with limited compute, the tests interfere with each other so they must not run at the same time. We desire to have no dependencies between tests because we want In summary, we don't need sequential, we need non-concurrency. |
It seems inappropriate for a test itself to retry because retrying means all the retries would get lumped together in one timing, which makes the timeouts not work properly, and the test reporter would have no visibility over the timing of each individual retry or that the test retried n times. |
Hmm. Can you wrap each test in
You can swap the default |
That was the first thing I tried except I used semaphores, but for some reason it didn't work. The test still failed. |
Ah yes, I see that it skips |
|
This slows the tests by 20s on my machine but is probably worth it for iteration speed. See UnkindPartition/tasty#414 for background. Change-Id: I4bd7f0ba24b29c4ce9bf18ea2842f57337c2dfa3
This slows the tests by 20s on my machine but is probably worth it for iteration speed, because it lets run individual tests (or groups) at our whim. See UnkindPartition/tasty#414 for background. Change-Id: I4bd7f0ba24b29c4ce9bf18ea2842f57337c2dfa3
This slows the tests by 20s on my machine but is probably worth it for iteration speed, because it lets run individual tests (or groups) at our whim. See UnkindPartition/tasty#414 for background. Change-Id: I4bd7f0ba24b29c4ce9bf18ea2842f57337c2dfa3
This slows the tests by 20s on my machine but is probably worth it for iteration speed, because it lets run individual tests (or groups) at our whim. See UnkindPartition/tasty#414 for background. Change-Id: I4bd7f0ba24b29c4ce9bf18ea2842f57337c2dfa3
@newhoggy could you possibly check the latest |
Thanks! |
main = defaultMain $ adjustOption (\_ -> QuickCheckTests 1000) $ testGroup ... then I think I'm looking for the API like main = defaultMainWithOptions [SomeOption (QuickCheckTests 100), ...] $ testGroup ... which would prepend option values. This could even override the |
I normally use |
Sometimes it is useful for a test suite to use a default that is different than the one that
tasty
uses.For example a test suite might have some concurrency issues and needs
NumThreads 1
to be able to run correctly.Whilst this can be done manually with
--num-threads 1
, ideally test-suites should be able to run correctly out of the box without additional flags.The text was updated successfully, but these errors were encountered: