{"size": 616, "ext": "js", "max_stars_repo_path": "tests/all.js", "max_stars_repo_name": "datagica/languages", "max_stars_repo_stars_event_min_datetime": "2017-06-11T03:31:19.000Z", "max_stars_repo_stars_event_max_datetime": "2021-11-23T14:58:54.000Z", "max_issues_repo_path": "tests/all.js", "max_issues_repo_name": "datagica/languages", "max_issues_repo_issues_event_min_datetime": "2016-05-22T17:51:23.000Z", "max_issues_repo_issues_event_max_datetime": "2016-06-15T13:16:37.000Z", "max_forks_repo_path": "tests/all.js", "max_forks_repo_name": "datagica/languages", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": 3, "max_issues_count": 3, "max_forks_count": null, "avg_line_length": 22.8148148148, "max_line_length": 66, "alphanum_fraction": 0.6396103896}
const util = require('util');
const chai = require('chai');
chai.use(require('chai-fuzzy'));
const expect = chai.expect;

const langs = require("../lib/datagica-languages");

// local functions
function pretty(obj) {
  return util.inspect(obj, false, 20, true);
}

describe('@datagica/languages', () => {

  it('should have the correct number of languages', () => {
    const stats = {
      all: langs.all.length,
      withIETF: langs.withIETF.length,
      ietf: Object.keys(langs.byIETF).length
    };
    console.log(pretty(stats));

    expect(stats).to.be.like({ all: 549, withIETF: 60, ietf: 60 })
  })

});
