You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use proptest for a finite state machine, but I'm having trouble finding a way to express that. I have 2 problems:
Explaining to the strategy that it found the terminal state and should stop
a. If I always return false from preconditions I get the error below
b. It doesn't seem to be possible to create an empty Strategy, that just wouldn't produce new states from transitions
I have a transition function in my STM that returns Result<Self, Error> when the supplied transition was not valid for the current state, this is not possible in the current ReferenceStateMachine, though I guess it could be worked around by implementing ReferenceStateMachine for a wrapper type
Test aborted: Too many local rejects
successes: 1
local rejects: 65536
65536 times at Pre-conditions were not satisfied
global rejects: 0
The text was updated successfully, but these errors were encountered:
Taking a step back from the current status of proptest-state-machine what would be the ideal situation you're looking for? Are you trying to emulate something you've done with other lanaguages/libraries? If so can you share examples? If not, could you describe how you would have expected things to work from an interface perspective. proptest-state-machine is a pre-1.0 release where we're trying to figure out the right things to offer so I don't want to get stuck too much in its current interfaces when thinking about new use cases.
Both examples in https://github.com/proptest-rs/proptest/tree/master/proptest-state-machine/examples seem to be infinite state machines.
I'm trying to use proptest for a finite state machine, but I'm having trouble finding a way to express that. I have 2 problems:
a. If I always return
false
frompreconditions
I get the error belowb. It doesn't seem to be possible to create an empty Strategy, that just wouldn't produce new states from
transitions
Result<Self, Error>
when the supplied transition was not valid for the current state, this is not possible in the currentReferenceStateMachine
, though I guess it could be worked around by implementingReferenceStateMachine
for a wrapper typeThe text was updated successfully, but these errors were encountered: