Skip to content

Commit

Permalink
add failing test for #44
Browse files Browse the repository at this point in the history
  • Loading branch information
Qix- committed Nov 26, 2021
1 parent fa09fac commit b7c685f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/basic.js
Original file line number Diff line number Diff line change
Expand Up @@ -180,3 +180,7 @@ assert.equal(string.to.hwb([280, 40, 60], 0), 'hwb(280, 40%, 60%, 0)');

assert.equal(string.to.keyword([255, 255, 0]), 'yellow');
assert.equal(string.to.keyword([100, 255, 0]), undefined);

// Make sure .get() doesn't return object prototype values (regression test, #44)
Object.keys(Object.getOwnPropertyDescriptors(Object.prototype))
.map(property => assert.deepStrictEqual([property, string.get(property)], [property, null]));

0 comments on commit b7c685f

Please sign in to comment.