Repository navigation
Roshini - Fix Task Completed Data Not Populating Across #5567
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: development
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| import { render, screen } from '@testing-library/react'; | ||
| import { MemoryRouter } from 'react-router-dom'; | ||
| import { describe, expect, it } from 'vitest'; | ||
| import AnniversaryCelebrated from './AnniversaryCelebrated'; | ||
|
|
||
| describe('AnniversaryCelebrated', () => { | ||
| it('renders without crashing when anniversary data is missing', () => { | ||
| render( | ||
| <MemoryRouter> | ||
| <AnniversaryCelebrated isLoading={false} data={undefined} darkMode={false} /> | ||
| </MemoryRouter>, | ||
| ); | ||
|
|
||
| expect(screen.getByText('No anniversaries found')).toBeInTheDocument(); | ||
|
Check failure on line 14 in src/components/TotalOrgSummary/AnniversaryCelebrated/AnniversaryCelebrated.test.jsx
|
||
| }); | ||
| }); | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| import { render, screen } from '@testing-library/react'; | ||
| import { describe, expect, it } from 'vitest'; | ||
| import BlueSquareStats from './BlueSquareStats'; | ||
|
|
||
| describe('BlueSquareStats', () => { | ||
| it('renders the empty-state when blueSquareStats is missing', () => { | ||
| render( | ||
| <BlueSquareStats | ||
| isLoading={false} | ||
| blueSquareStats={undefined} | ||
| comparisonType="previous" | ||
| darkMode={false} | ||
| />, | ||
| ); | ||
|
|
||
| expect(screen.getByText('No Blue Square data available for this period.')).toBeInTheDocument(); | ||
| }); | ||
| }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This newly added test fails on the current head: the missing-data branch renders 'No anniversary data available for this period.', not 'No anniversaries found'. Running all four new suites yields 5 passes / 1 failure. Please assert the intended empty-state message so the PR's regression tests pass.