Errors in function reference examples
PR #2452 adds tests that reveal 89 of the function reference pages have errors in their code examples. While some of them are simple syntax errors like a missing close parenthesis (e.g., the second-to-last example in https://mathjs.org/docs/reference/functions/isNumeric.html), some are significant departures in functionality from what's documented (e.g., the only example in https://mathjs.org/docs/reference/functions/sqrtm.html actually produces Error: computing square root of matrix: iterative method could not converge).
In any case, it seems to me that all of them should eventually be fixed, so that then going forward we can use the new test to ensure that mathjs always conforms to the documented behavior.
Currently doc.test.js merely prints the discrepancies rather than failing, but as they are fixed we can progressively remove the allowances for the discrepancies.
Thanks, I like this idea of unit testing the examples 👍