{"size": 1087, "ext": "js", "max_stars_repo_path": "__tests__/Employee.test.js", "max_stars_repo_name": "Dannymont94/team-profile-generator", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "__tests__/Employee.test.js", "max_issues_repo_name": "Dannymont94/team-profile-generator", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "__tests__/Employee.test.js", "max_forks_repo_name": "Dannymont94/team-profile-generator", "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": 31.9705882353, "max_line_length": 79, "alphanum_fraction": 0.6715731371}
const Employee = require('../lib/Employee');

test('creates an Employee object', () => {
  const employee = new Employee('Dave', 'D123', 'dave@company.com');

  expect(employee.name).toBe('Dave');
  expect(employee.id).toBe('D123');
  expect(employee.email).toBe('dave@company.com');
  expect(employee.role).toBe('Employee');
});

test('gets employee\'s name', () => {
  const employee = new Employee('Dave', 'D123', 'dave@company.com');

  expect(employee.getName()).toEqual(expect.stringContaining(employee.name));
});

test('gets employee\'s id', () => {
  const employee = new Employee('Dave', 'D123', 'dave@company.com');

  expect(employee.getId()).toEqual(expect.stringContaining(employee.id));
});

test('gets employee\'s email', () => {
  const employee = new Employee('Dave', 'D123', 'dave@company.com');

  expect(employee.getEmail()).toEqual(expect.stringContaining(employee.email));
});

test('gets employee\'s role', () => {
  const employee = new Employee('Dave', 'D123', 'dave@company.com');

  expect(employee.getRole()).toEqual(expect.stringContaining('Employee'));
});