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

feat: add test generation models #180 #328

Merged
merged 5 commits into from
Oct 9, 2024

Conversation

DavePearce
Copy link
Collaborator

No description provided.

The concept of an `Enumerator` replaces the existing concept of a
`BaseIterator`.  Furthermore, functionality is provided for enumerating
all combinations of a given set for a fixed value of `n`.
Property assertions are now operational again.  The key is that, for a
valid trace, all property assertions should hold.  However, for invalid
traces (i.e. where the given constraints fail) then we cannot expect a
property assertion to hold.
This puts in place a preliminary property-based testing framework which
will enumerate inputs and compare against a test oracle (as determined
by property assertions embedded within the constraints file).
This adds support for a "test generator" which automatically generates
test traces, and splits them using a given "oracle".  The latter is a
piece of Go code written specifically for this task.
This tweaks the test command so that it doesn't treat property
assertions as "absolute truth".  Rather, it attempts to find traces
which are accepted but where the property assertions don't hold.

At this stage, the system is fairly simplistic.  We need to think more
carefully about how to generate the traces.  This includes avoiding the
brute-force enumeration currently in play.  Likewise, thinking more
carefully about the "pool" of values used for testing.
@DavePearce DavePearce linked an issue Oct 9, 2024 that may be closed by this pull request
@DavePearce DavePearce merged commit b687f2e into main Oct 9, 2024
2 checks passed
@DavePearce DavePearce deleted the 130-add-test-generation-models branch October 9, 2024 18:11
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.

Add Test Generation Models
1 participant