-
Notifications
You must be signed in to change notification settings - Fork 95
Testing
Josh Hiles edited this page Dec 22, 2023
·
1 revision
When running your test suite, it's helpful to know that the experimental results always match. To help with testing, Scientist has a ThrowOnMismatches property that can be set to true. Only do this in your test suite!
To throw on mismatches:
Scientist.Science<int>("ExperimentN", experiment =>
{
experiment.ThrowOnMismatches = true;
// ...
});Scientist will throw a MismatchException<T, TClean> exception if any observations don't match.
- Publishing results
- Controlling comparison
- Adding context
- Expensive setup
- Keeping it clean
- Ignoring mismatches
- Enabling or disabling experiments
- Ramping up experiments
- Running candidates in parallel (asynchronous)
- Testing
- Handling errors
- Designing an experiment
- Finishing an experiment
Sometimes scientists just gotta do weird stuff. We understand.