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
{{ message }}
This repository has been archived by the owner on Mar 10, 2022. It is now read-only.
Although shouldBe() is usually called as: shouldBe("actual", "expected");, the function supports an optional
tolerance value, such as: 'shouldBe("actual", "expected", tolerance);, then our transformation to assert_equals(actual, expected);` would be incorrect.
This is should be relatively easy to fix, but is a more general issue of dealing with optional parameters in js-test.js functions. We need to remove these parameters before transforming to testharness.js functions, since we usually update the arguments array in place (meaning the third parameter would still be present if the testharness.js function only has 2).
These mistakes would fail verification, so would hopefully be caught by the person running the tool.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Although
shouldBe()
is usually called as:shouldBe("actual", "expected");
, the function supports an optionaltolerance value, such as: 'shouldBe("actual", "expected", tolerance);
, then our transformation to
assert_equals(actual, expected);` would be incorrect.This is should be relatively easy to fix, but is a more general issue of dealing with optional parameters in
js-test.js
functions. We need to remove these parameters before transforming totestharness.js
functions, since we usually update the arguments array in place (meaning the third parameter would still be present if thetestharness.js
function only has 2).These mistakes would fail verification, so would hopefully be caught by the person running the tool.
The text was updated successfully, but these errors were encountered: