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
The question is: can I merge some of our tests to this repo?
The main idea behind this would be to test our tests. If attaswift/BigInt fails some case then it may mean that the test is wrong, in which case we have to fix our code in Violet.
Violet test suite is quite big (but by no means it is exhausting the test-space). We went with property based testing with means that we test millions of inputs to check if the general rule holds (for example: a+b=c -> c-a=b etc.). This takes time, but pays for itself by finding weird overflows in bit operations (we store “sign + magnitude”, so bit operations are a bit difficult to implement).
You can preview our tests at Violet -> BigIntTests. Though I would advise reading our documentation before, because our design is quite different than yours.
The text was updated successfully, but these errors were encountered:
Ok.
I will work on it next week.
Obviously it will be multiple smaller PRs rather than a single big one. All of them will be linked to this issue.
Btw. can I create a new target for it? Something like "VioletBigIntTests". This will simplify the code ownership: everything connected to this target will be owned by me (for example new issue/PR -> I am responsible).
Hi,
As I mentioned in #97 Using
ManagedBufferPointer
instead ofArray
as a storage I also implemented my own version ofBigInt
for Violet - Python VM written in Swift.The question is: can I merge some of our tests to this repo?
The main idea behind this would be to test our tests. If
attaswift/BigInt
fails some case then it may mean that the test is wrong, in which case we have to fix our code in Violet.Violet test suite is quite big (but by no means it is exhausting the test-space). We went with property based testing with means that we test millions of inputs to check if the general rule holds (for example: a+b=c -> c-a=b etc.). This takes time, but pays for itself by finding weird overflows in bit operations (we store “sign + magnitude”, so bit operations are a bit difficult to implement).
You can preview our tests at Violet -> BigIntTests. Though I would advise reading our documentation before, because our design is quite different than yours.
The text was updated successfully, but these errors were encountered: