move babel config

This commit is contained in:
Matthias Kretschmann 2020-02-25 20:40:46 +01:00
parent cf6157b434
commit c3d4a7f42f
Signed by: m
GPG Key ID: 606EEEF3C479A91F
3 changed files with 4 additions and 5 deletions

View File

@ -1,11 +1,10 @@
import React from 'react'
import { render, wait } from '@testing-library/react'
import { render } from '@testing-library/react'
import Layout from '../src/renderer/Layout'
describe('Layout', () => {
it('renders correctly', async () => {
it('renders correctly', () => {
const { container } = render(<Layout>Hello</Layout>)
await wait()
expect(container.firstChild).toBeInTheDocument()
})
})

View File

@ -1,4 +1,4 @@
const { devDependencies } = require('./package.json')
const { devDependencies } = require('../package.json')
module.exports = {
presets: [

View File

@ -1,7 +1,7 @@
module.exports = {
rootDir: '../',
transform: {
'^.+\\.[t|j]sx?$': 'babel-jest'
'^.+\\.[t|j]sx?$': ['babel-jest', { configFile: './tests/babel.config.js' }]
},
moduleNameMapper: {
'.+\\.(css|styl|less|sass|scss)$': 'identity-obj-proxy',