import { getDayNames } from '..';

jest.mock('@transferwise/formatting', () => ({
  formatDate: (day) => day.getDay(),
}));

describe('getDayNames', () => {
  it('returns all weekdays', () => {
    expect(getDayNames('en')).toHaveLength(7);
  });

  it('starts with Monday and ends with Sunday', () => {
    const days = getDayNames('en');
    expect(days[0]).toBe(1);
    expect(days[days.length - 1]).toBe(0);
  });
});
