function expectArraysToBeEqual(a1, a2, len) {
            expect(a2.length).toEqual(a1.length);
            a2.forEach(function (entry, index) {
                expect(entry).toEqual(a1[index]);
            });
        }
Expects arrays to be of specified length and equal.
@param {Array} a1 Result to test
@param {Array} a2 Expected values.
@param {number} len Expected length.