Sha256: 5583b41d6c33336dae93efd53e861908e40bdb878e2375af7f62a01163fca6f4

Contents?: true

Size: 1.16 KB

Versions: 208

Compression:

Stored size: 1.16 KB

Contents

import Squares from './difference-of-squares';

describe('Squares', () => {

  describe('up to 5', () => {
    const squares = new Squares(5);

    it('gets the square of sums', () => {
      expect(squares.squareOfSums).toBe(225);
    });

    xit('gets the sum of squares', () => {
      expect(squares.sumOfSquares).toBe(55);
    });

    xit('gets the difference', () => {
      expect(squares.difference).toBe(170);
    });

  });

  describe('up to 10', () => {
    const squares = new Squares(10);

    xit('gets the square of sums', () => {
      expect(squares.squareOfSums).toBe(3025);
    });

    xit('gets the sum of squares', () => {
      expect(squares.sumOfSquares).toBe(385);
    });

    xit('gets the difference', () => {
      expect(squares.difference).toBe(2640);
    });

  });

  describe('up to 100', () => {
    const squares = new Squares(100);

    xit('gets the square of sums', () => {
      expect(squares.squareOfSums).toBe(25502500);
    });

    xit('gets the sum of squares', () => {
      expect(squares.sumOfSquares).toBe(338350);
    });

    xit('gets the difference', () => {
      expect(squares.difference).toBe(25164150);
    });

  });

});

Version data entries

208 entries across 208 versions & 1 rubygems

Version Path
trackler-2.1.0.53 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.52 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.51 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.50 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.49 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.48 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.47 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.46 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.45 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.44 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.43 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.42 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.41 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.40 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.39 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.38 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.37 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.36 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.34 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js
trackler-2.1.0.33 tracks/ecmascript/exercises/difference-of-squares/difference-of-squares.spec.js