mirror of
https://github.com/andwati/blog-nest.git
synced 2026-11-26 05:48:49 +00:00
Refactor code structure for improved readability and maintainability
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
import { render, screen } from '@testing-library/react'
|
||||
|
||||
import Home from './page'
|
||||
|
||||
jest.mock('next/image', () => ({
|
||||
__esModule: true,
|
||||
default: (props: React.ImgHTMLAttributes<HTMLImageElement>) => (
|
||||
// biome-ignore lint/a11y/useAltText: mock
|
||||
<img {...props} />
|
||||
),
|
||||
}))
|
||||
|
||||
describe('Home', () => {
|
||||
it('renders the Next.js logo', () => {
|
||||
render(<Home />)
|
||||
const logo = screen.getByAltText('Next.js logo')
|
||||
expect(logo).toBeInTheDocument()
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user