"use strict";

var _tape = _interopRequireDefault(require("tape"));

var _formatNumber = require("./format-number");

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

const tests = [[null, '0'], [undefined, '0'], [0, '0'], [1234.75, '1,234.75'], [549000000, '549,000,000'], [549000000.2432423423, '549,000,000.243'], [1234, '1,234'], [100, '100']];
(0, _tape.default)('addCommas', t => {
  tests.forEach(([input, output]) => {
    t.equal((0, _formatNumber.addCommas)(input), output, "".concat(input, " should be ").concat(output));
  });
  t.end();
});