overleaf/services/web/test/frontend/features/hotkeys-modal/components/hotkeys-modal-bottom-text.test.jsx
Jakob Ackermann 9daa8f5d98 Merge pull request #15040 from overleaf/jpa-js-to-jsx
[web] rename all the JSX files to .jsx/.tsx

GitOrigin-RevId: 82056ae47e017523722cf258dcc83c8a925a28f7
2023-09-29 08:04:29 +00:00

21 lines
671 B
JavaScript

import { render, screen } from '@testing-library/react'
import { expect } from 'chai'
import HotkeysModalBottomText from '../../../../../frontend/js/features/hotkeys-modal/components/hotkeys-modal-bottom-text'
describe('<HotkeysModalBottomText />', function () {
it('renders the correct text', function () {
render(<HotkeysModalBottomText />)
screen.getByText(
/A more comprehensive list of keyboard shortcuts can be found in/
)
const link = screen.getByRole('link', {
name: /this Overleaf project template/,
})
expect(link.getAttribute('href')).to.equal(
`/articles/overleaf-keyboard-shortcuts/qykqfvmxdnjf`
)
})
})