<commit_before>import alternatingSums from '../../src/alternating-sums'

describe('alternatingSums()', () => {

   context('always', () => {
     it('should return an array', () => {
       let input = [[32,54,123,43],[42,432]];
       input.forEach((myArray) => {
           expect(alternatingSums(myArray)).to.be.an('array');
       });
     });
   });

  const _testArray = [
    {input: [50, 60, 60, 45, 70], output: [180, 105]},
    {input: [100, 50], output: [100, 50]},
    {input: [100], output: [100, 0]},
    {input: [], output: [0, 0]}
  ]

  _testArray.forEach((object) => {
    context(`for [${object.input}]`, () => {
      it(`should return [${object.output}]`, () => {
        expect(alternatingSums(object.input)).to.be.deep.equal(object.output);
      })
    });
  })
});<commit_msg>Removed context, code cleaned-up using prettier, destructuring used in forEach<commit_after>import alternatingSums from '../../src/alternating-sums';

describe('alternatingSums()', () => {
  it('always should return an array', () => {
    const _input = [[32, 54, 123, 43], [42, 432]];
    _input.forEach(myArray => {
      expect(alternatingSums(myArray)).to.be.an('array');
    });
  });

  const _testArray = [
    { input: [50, 60, 60, 45, 70], output: [180, 105] },
    { input: [100, 50], output: [100, 50] },
    { input: [100], output: [100, 0] },
    { input: [], output: [0, 0] }
  ];

  _testArray.forEach(({input, output}) => {
    it(`for [${input}] should return [${output}]`, () => {
      expect(alternatingSums(input)).to.be.deep.equal(output);
    });
  });
});
{'fraction_non_alphanumeric': 0.23291139240506328, 'fraction_numerical': 0.0620253164556962, 'mean_word_length': 3.1825396825396823, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '336391', 'n_tokens_mistral': 633, 'n_tokens_neox': 546, 'n_words': 111}