MCPcopy
hub / github.com/josdejong/mathjs / testSimplifyCore

Function testSimplifyCore

test/unit-tests/function/algebra/simplifyCore.test.js:7–12  ·  view source on GitHub ↗
(expr, expected, opts = {}, simpOpts = {})

Source from the content-addressed store, hash-verified

5
6describe('simplifyCore', function () {
7 const testSimplifyCore = function (expr, expected, opts = {}, simpOpts = {}) {
8 let actual = math.simplifyCore(math.parse(expr), simpOpts).toString(opts)
9 assert.strictEqual(actual, expected)
10 actual = math.simplifyCore(expr, simpOpts).toString(opts)
11 assert.strictEqual(actual, expected)
12 }
13
14 it('should handle different node types', function () {
15 testSimplifyCore('5*x*3', '3 * 5 * x')

Callers 1

Calls 3

toStringMethod · 0.65
simplifyCoreMethod · 0.65
parseMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…