to-percent-js
Advanced tools
Comparing version 0.3.2 to 0.3.3
@@ -89,2 +89,5 @@ "use strict"; | ||
}); | ||
it("Test zero", function () { | ||
(0, _chai.expect)((0, _index.toInt)("-0")).to.equal(0); | ||
}); | ||
}); | ||
@@ -91,0 +94,0 @@ describe("Get Num", function () { |
@@ -44,3 +44,3 @@ "use strict"; | ||
if (maybeFloat === maybeInt && maybeInt + "" === maybeString) { | ||
if (maybeFloat === maybeInt && (maybeInt + "" === maybeString || 0 === maybeInt)) { | ||
return maybeInt; | ||
@@ -47,0 +47,0 @@ } else { |
@@ -85,2 +85,5 @@ "use strict"; | ||
}); | ||
it("Test zero", function () { | ||
expect(toInt("-0")).to.equal(0); | ||
}); | ||
}); | ||
@@ -87,0 +90,0 @@ describe("Get Num", function () { |
@@ -29,3 +29,3 @@ import _typeof from "reshow-runtime/es/helpers/typeof"; | ||
if (maybeFloat === maybeInt && maybeInt + "" === maybeString) { | ||
if (maybeFloat === maybeInt && (maybeInt + "" === maybeString || 0 === maybeInt)) { | ||
return maybeInt; | ||
@@ -32,0 +32,0 @@ } else { |
{ | ||
"name": "to-percent-js", | ||
"version": "0.3.2", | ||
"version": "0.3.3", | ||
"description": "Change number to percentage.", | ||
@@ -5,0 +5,0 @@ "repository": "react-atomic/react-atomic-organism", |
13441
386