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

Generator and simplifier for property based tests #67

Open
typesanitizer opened this issue Dec 3, 2017 · 1 comment
Open

Generator and simplifier for property based tests #67

typesanitizer opened this issue Dec 3, 2017 · 1 comment

Comments

@typesanitizer
Copy link
Contributor

In #14, you suggested that we should have property based testing of the simplifier.

  • I think the same generator will be useful for a variety of other tests later on (e.g. an integration test from simplification to code gen), so it would be very useful to have a good shrinker with it.
  • I saw this fun ICFP talk [paper] about compiler testing using code generation. I don't know if this is directly helpful but maybe their citations help in writing a good generator or shrinker. While many of the examples given rely on being able to perform IO arbitrarily, some like (/) 0 (let e = not in pred 1) don't depend on this. It might be a good test to check that the output is identical for different optimization levels etc.
@typesanitizer typesanitizer changed the title Property based testing - writing a generator and simplifier Generator and simplifier for property based tests Dec 3, 2017
@ollef
Copy link
Owner

ollef commented Dec 3, 2017

This would be great to have!

I think even something quite simple-minded (e.g. only supporting a couple of fixed types) might help a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants