{"size": 646, "ext": "js", "max_stars_repo_path": "test/_test-matchers.js", "max_stars_repo_name": "iFrostizz/node-notifier", "max_stars_repo_stars_event_min_datetime": "2015-01-01T09:15:48.000Z", "max_stars_repo_stars_event_max_datetime": "2022-03-30T19:15:47.000Z", "max_issues_repo_path": "test/_test-matchers.js", "max_issues_repo_name": "iFrostizz/node-notifier", "max_issues_repo_issues_event_min_datetime": "2015-01-13T11:34:02.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-31T19:13:38.000Z", "max_forks_repo_path": "test/_test-matchers.js", "max_forks_repo_name": "iFrostizz/node-notifier", "max_forks_repo_forks_event_min_datetime": "2015-01-12T13:10:41.000Z", "max_forks_repo_forks_event_max_datetime": "2022-03-23T12:23:38.000Z"}
{"max_stars_count": 5354, "max_issues_count": 341, "max_forks_count": 404, "avg_line_length": 28.0869565217, "max_line_length": 73, "alphanum_fraction": 0.6439628483}
expect.extend({
  toEndWith(received, actual) {
    const pass = endsWith(received, actual);
    const message = () =>
      `expected ${received} ${pass ? 'not ' : ''} to end with ${actual}`;
    return { message, pass };
  }
});

function endsWith(subjectString, searchString, position) {
  if (
    typeof position !== 'number' ||
    !isFinite(position) ||
    Math.floor(position) !== position ||
    position > subjectString.length
  ) {
    position = subjectString.length;
  }
  position -= searchString.length;
  const lastIndex = subjectString.lastIndexOf(searchString, position);
  return lastIndex !== -1 && lastIndex === position;
}
