Skip to content

Commit 29a052c

Browse files
authored
test(DashboardClient): verify generate your own button points to root / (JhaSourav07#1132)
## Description Fixes JhaSourav07#1093 ## Pillar - [x] 🛠️ Other (Bug fix, refactoring, docs) ## Visual Preview No visual changes — this is a test-only PR. ## Checklist before requesting a review: - [x] I have read the `CONTRIBUTING.md` file. - [x] I have tested these changes locally. - [x] I have run `npm run format` and `npm run lint` locally and resolved all errors. - [x] My commits follow the Conventional Commits format. - [x] I have made sure that i have only one commit to merge in this PR. - [x] I have starred the repo.
2 parents 9aed6c2 + 922e38e commit 29a052c

2 files changed

Lines changed: 36 additions & 11 deletions

File tree

components/dashboard/DashboardClient.test.tsx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,4 +233,10 @@ describe('DashboardClient', () => {
233233
expect(screen.getAllByText('Shivangi').length).toBeGreaterThan(0);
234234
expect(screen.getAllByText('Sourav').length).toBeGreaterThan(0);
235235
});
236+
it('generate your own button points to root /', () => {
237+
render(<DashboardClient initialData={mockInitialData} username="Shivangi1515" />);
238+
239+
const generateLink = screen.getByRole('link', { name: /generate your own/i });
240+
expect(generateLink.getAttribute('href')).toBe('/');
241+
});
236242
});

package-lock.json

Lines changed: 30 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)