Skip to content

Commit

Permalink
fix sonar issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Ashish8689 committed May 30, 2024
1 parent 0c47787 commit 934d06d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ import { isActiveAnnouncement } from './AnnouncementsUtils';
describe('Test isActiveAnnouncement utility', () => {
jest.useFakeTimers('modern').setSystemTime(new Date('2024-02-05'));

it('should return false for active', () => {
it('should return true for active announcement', () => {
const result = isActiveAnnouncement(
new Date('moment().format()').getTime(),
new Date('2024-02-03').getTime(),
new Date('2024-02-10').getTime()
);

expect(result).toBe(true);
});

it('should return true for inActive', () => {
it('should return false for inActive announcements', () => {
const result = isActiveAnnouncement(
new Date('2024-02-01').getTime(),
new Date('2024-02-04').getTime()
Expand Down

0 comments on commit 934d06d

Please sign in to comment.