mirror of
https://github.com/jxnblk/mdx-deck.git
synced 2024-11-05 06:06:17 +03:00
Adjust tests
This commit is contained in:
parent
903985fff5
commit
65aaf342c5
@ -11,11 +11,12 @@ context('MDX Deck', () => {
|
||||
cy.contains('MDX Deck')
|
||||
})
|
||||
|
||||
/* doesn't work
|
||||
/* doesn't work?? */
|
||||
it('goes to the next slide', () => {
|
||||
cy.get('body')
|
||||
.type('{rightarrow}')
|
||||
.trigger('keydown', {
|
||||
keyCode: 39,
|
||||
})
|
||||
.contains('Presentation')
|
||||
})
|
||||
*/
|
||||
})
|
||||
|
@ -6,7 +6,8 @@
|
||||
"license": "MIT",
|
||||
"repository": "github:jxnblk/mdx-deck",
|
||||
"scripts": {
|
||||
"start": "gatsby develop --open"
|
||||
"start": "gatsby develop --open",
|
||||
"test": "jest"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"gatsby": "^2.14.0",
|
||||
@ -28,5 +29,30 @@
|
||||
"devDependencies": {
|
||||
"cypress": "^3.4.0",
|
||||
"lerna": "^3.13.1"
|
||||
},
|
||||
"jest": {
|
||||
"testMatch": [
|
||||
"**/test/*.js"
|
||||
],
|
||||
"testPathIgnorePatterns": [
|
||||
"/node_modules/",
|
||||
"/fixtures/"
|
||||
],
|
||||
"coverageReporters": [
|
||||
"lcov",
|
||||
"text",
|
||||
"html"
|
||||
],
|
||||
"collectCoverageFrom": [
|
||||
"**/src/**/*.js"
|
||||
],
|
||||
"coverageThreshold": {
|
||||
"global": {
|
||||
"branches": 80,
|
||||
"functions": 80,
|
||||
"lines": 80,
|
||||
"statements": 80
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
12
packages/gatsby-plugin/test/deck.js
Normal file
12
packages/gatsby-plugin/test/deck.js
Normal file
@ -0,0 +1,12 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
render,
|
||||
fireEvent,
|
||||
cleanup
|
||||
} from '@testing-library/react'
|
||||
import Deck from '../src/deck'
|
||||
|
||||
afterEach(cleanup)
|
||||
|
||||
test('renders', () => {
|
||||
})
|
Loading…
Reference in New Issue
Block a user