Skip to content

Commit

Permalink
🐛 Fix timepicker test fail at 12am/pm in 12 hour format (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
prateekshourya29 authored Jun 3, 2021
1 parent 34c0b38 commit 0c82476
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion __tests__/components/DatePicker/TimePicker.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ describe('TimePicker', () => {
const timePickerContainer = document.querySelector('.rc-tooltip').querySelector('.sha-el-row');

const hours = timePickerContainer.querySelector('.hour-column').querySelectorAll('p');
expect(hours[Number(currentTime[0])]).toHaveStyle(`
expect(hours[Number(currentTime[0] === '12' ? '0' : currentTime[0])]).toHaveStyle(`
background: #536DFE;
`);

Expand Down

0 comments on commit 0c82476

Please sign in to comment.