Skip to content

Commit

Permalink
Learn more button navigate
Browse files Browse the repository at this point in the history
* Clicking learn more button navigates to dpdash page
  • Loading branch information
Elkrival committed Jun 6, 2024
1 parent 60f0ffa commit 66d78cb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
8 changes: 8 additions & 0 deletions views/components/HeroCard/HeroCard.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,12 @@ describe('Hero Component', () => {

expect(learnMoreButton).toBeDefined()
})
test('Learn More button has href attribuates', () => {
const learnMoreButton = screen.getByText('Learn More')

expect(learnMoreButton).toHaveAttribute(
'href',
'https://sites.google.com/g.harvard.edu/dpdash/'
)
})
})
3 changes: 3 additions & 0 deletions views/components/HeroCard/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ const HeroCard = () => {
size="small"
endIcon={<ArrowForwardOutlined />}
variant="outlined"
href="https://sites.google.com/g.harvard.edu/dpdash/"
target="_blank"
rel="noopener noreferrer"
>
Learn More
</Button>
Expand Down

0 comments on commit 66d78cb

Please sign in to comment.