mirror of
https://github.com/kremalicious/portfolio.git
synced 2024-06-10 19:31:03 +02:00
Matthias Kretschmann
447cada700
* next.js + typescript * more testing * script updates * fixes * favicon generation * testing * readme updates * tweaks * tweaks * move tests * image tweaks * ci tweaks * commit next-env.d.ts for ci * migrations * fixes * fixes * ci tweaks * new animations * project preview tweaks * add codeclimate config * dark mode refactor, test tweaks * readme updates * animation tweaks * animate in loaded images * test update * update humans.txt
24 lines
595 B
TypeScript
24 lines
595 B
TypeScript
import React from 'react'
|
|
import { render, act } from '@testing-library/react'
|
|
import Meta from '.'
|
|
|
|
describe('Meta', () => {
|
|
it('renders without crashing', async () => {
|
|
await act(async () => {
|
|
render(<Meta title="Hello World" />, {
|
|
container: document.head
|
|
})
|
|
})
|
|
expect(document.title).toBe('Hello World')
|
|
})
|
|
|
|
it('renders without crashing with slug', async () => {
|
|
await act(async () => {
|
|
render(<Meta title="Hello World" slug="hello" />, {
|
|
container: document.head
|
|
})
|
|
})
|
|
expect(document.title).toBe('Hello World')
|
|
})
|
|
})
|