{"size": 531, "ext": "js", "max_stars_repo_path": "test/chapter1/1-5.js", "max_stars_repo_name": "FloripaCodeAndMagic/cracking", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "test/chapter1/1-5.js", "max_issues_repo_name": "FloripaCodeAndMagic/cracking", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "test/chapter1/1-5.js", "max_forks_repo_name": "FloripaCodeAndMagic/cracking", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 27.9473684211, "max_line_length": 91, "alphanum_fraction": 0.6195856874}
const expect = require('chai').expect;
const oneDotFive = require('../../src/chapter1/1-5');

describe('1-5', function() {
    it('should compress big things', function() {
       const input = 'aabcccccaaa';
       const expected = 'a2b1c5a3';

       expect(oneDotFive(input)).to.be.equal(expected);
    });

    it('should not compress if string would not become smaller than original', function() {
       const input = 'abc';
       const expected = 'abc';

       expect(oneDotFive(input)).to.be.equal(expected);
    });
});
