diff options
author | wout <wout@impinc.co.uk> | 2013-06-30 11:16:59 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2013-06-30 11:16:59 +0100 |
commit | 578c2bd6dffed8a636e64dbfbfedd3eb53539665 (patch) | |
tree | 93f656fb9087233bd189c93b53696cd3548242fa /spec | |
parent | e4fb8522a2c57069b2523f16de92d5eb7e6dd85e (diff) | |
download | svg.js-578c2bd6dffed8a636e64dbfbfedd3eb53539665.tar.gz svg.js-578c2bd6dffed8a636e64dbfbfedd3eb53539665.zip |
Fix in unit parser with negative values.
Diffstat (limited to 'spec')
-rw-r--r-- | spec/spec/number.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/spec/number.js b/spec/spec/number.js index 62e51a2..3d1876c 100644 --- a/spec/spec/number.js +++ b/spec/spec/number.js @@ -23,6 +23,11 @@ describe('Number', function() { expect(number.value).toBe(0.99) expect(number.unit).toBe('%') }) + it('parses a negative percent value', function() { + number = new SVG.Number('-89%') + expect(number.value).toBe(-0.89) + expect(number.unit).toBe('%') + }) }) |