Skip to content

Commit

Permalink
test: migrate from jest to peeky
Browse files Browse the repository at this point in the history
  • Loading branch information
Akryum committed Jan 14, 2022
1 parent b064dcd commit 3cf5444
Show file tree
Hide file tree
Showing 4 changed files with 1,304 additions and 1,202 deletions.
39 changes: 0 additions & 39 deletions packages/floating-vue/jest.config.js

This file was deleted.

7 changes: 2 additions & 5 deletions packages/floating-vue/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"prepublishOnly": "yarn run lint && yarn run test && yarn run build",
"test": "yarn run test:unit",
"lint": "eslint . --ext .js,.vue",
"test:unit": "jest"
"test:unit": "peeky run"
},
"main": "dist/floating-vue.umd.js",
"module": "dist/floating-vue.esm.js",
Expand Down Expand Up @@ -37,13 +37,10 @@
"eslint-plugin-promise": "^4.2.1",
"eslint-plugin-vue": "^7.4.0",
"fs-extra": "^9.0.1",
"jest": "^24.7.1",
"jest-serializer-vue": "^2.0.2",
"jest-transform-stub": "^2.0.0",
"@peeky/test": "^0.10.2",
"typescript": "^4.5.4",
"vite": "^2.7.12",
"vite-plugin-vue2": "^1.9.2",
"vue-jest": "^3.0.7",
"vue-template-compiler": "^2.6.10",
"vue-typegen": "^0.2.0"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
import * as VTooltip from './v-tooltip'
/* eslint-disable import/first */

jest.mock('@popperjs/core', () => ({
peeky.mockModule('@popperjs/core', () => ({
placements: ['top', 'top-start', 'top-end', 'bottom', 'bottom-start', 'bottom-end', 'right', 'right-start', 'right-end', 'left', 'left-start', 'left-end', 'auto', 'auto-start', 'auto-end'],
}))

import { describe, test, expect } from '@peeky/test'
import * as VTooltip from './v-tooltip'

describe('getPlacement', () => {
test('object notation', () => {
const value = {
Expand Down
Loading

0 comments on commit 3cf5444

Please sign in to comment.