-
Notifications
You must be signed in to change notification settings - Fork 1
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
Willow parameters for testing? #17
Comments
We could probably benefit from using rstest in these cases. It provides a neat means of creating test fixtures and parametrised tests. There are lots of good usage examples in the p2panda codebase 🐼 |
Not sure if rstest helps too much with supplying choices type parameters ("generics"), though. |
This question isn't so much about setting up specific states with reusable items (e.g. give me a So my question is: do we do what willow-js does (fantasy protocol with reasonable constraints) or just use Earthstar's parameters, which are all defined already?
|
As someone who hopefully won't need to implement any of it, I'd prefer using the Earthstar parameters directly =P |
From here on out, testing our modules will require an increasing number of Willow parameters to be configured.
In willow-js, I made a kind of test scheme with extremely simplified parameters:
NamespaceId
was an enum ofProject
,Work
,Family
;SubspaceId
was an enum ofAlfie
,Betty
,Gemma
etc. The sometimes tricky aspect of this was making sure that these simple parameters weren't too simple and actually tested the properties of Willow. And some end can't be simple, like the parameters for private area intersection.So I suggest there's two ways we can go with this: either devise a minimally viable set of parameters for use in testing, or use a real set of parameters, e.g. Earthstar's.
The text was updated successfully, but these errors were encountered: