rwwagner90/ember-math-helpers

View on GitHub
test-app/tests/unit/helpers/sum-test.js

Summary

Maintainability
A
0 mins
Test Coverage
import { sum } from 'ember-math-helpers/helpers/sum';
import { add } from 'ember-math-helpers/helpers/add';
import { module, test } from 'qunit';

module('Unit | Helper | sum', function () {
  test('works as alias to add', function (assert) {
    const input = [20, 10];
    assert.strictEqual(sum(input), add(input));
  });

  test('works as alias to add for multiple arguments', function (assert) {
    const input = [1, 2, 3, 4, 5];
    assert.strictEqual(sum(input), add(input));
  });
});