Closed ruipin closed 3 years ago
Commit https://github.com/ruipin/fvtt-lib-wrapper/commit/26f097024a37b2b088514117809a6b3f75dd231b implements checker CallOrderChecker which allows automatic checking of wrapper call order, including detailed validation of argument passing, return values, and this. It also helps make unit tests much more readable.
CallOrderChecker
this
Before: https://github.com/ruipin/fvtt-lib-wrapper/blob/8cddf9f593e8587739fa3f9269ca7b55a775b07e/tests/test_wrapper.js After: https://github.com/ruipin/fvtt-lib-wrapper/blob/26f097024a37b2b088514117809a6b3f75dd231b/tests/test_wrapper.js
These changes allowed me to easily find bug #13.
As such, the remaining test cases (e.g. test_lib.js) should be ported to use this checker.
test_lib.js
This is now done.
Commit https://github.com/ruipin/fvtt-lib-wrapper/commit/26f097024a37b2b088514117809a6b3f75dd231b implements checker
CallOrderChecker
which allows automatic checking of wrapper call order, including detailed validation of argument passing, return values, andthis
. It also helps make unit tests much more readable.Before: https://github.com/ruipin/fvtt-lib-wrapper/blob/8cddf9f593e8587739fa3f9269ca7b55a775b07e/tests/test_wrapper.js After: https://github.com/ruipin/fvtt-lib-wrapper/blob/26f097024a37b2b088514117809a6b3f75dd231b/tests/test_wrapper.js
These changes allowed me to easily find bug #13.
As such, the remaining test cases (e.g.
test_lib.js
) should be ported to use this checker.