feat: factories can depend on the presence of types
All checks were successful
/ test (pull_request) Successful in 17s
All checks were successful
/ test (pull_request) Successful in 17s
Refactors each TypeDispatcher to have its own separate collection of types. Add isnan function which returns a boolean if that type is present, otherwise returns the number 1 for true, and 0 for fase.
This commit is contained in:
parent
a7673216c1
commit
b2b41d6348
8 changed files with 43 additions and 16 deletions
|
@ -6,4 +6,8 @@ describe('the numbers-only bundle', () => {
|
|||
assert.strictEqual(math.quotient(5, 3), 1)
|
||||
assert.strictEqual(math.square(-3), 9)
|
||||
})
|
||||
it('uses 1 and 0 instead of true and false', () => {
|
||||
assert.strictEqual(math.isnan(-16.5), 0)
|
||||
assert.strictEqual(math.isnan(NaN), 1)
|
||||
})
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue