chore: move tests
This commit is contained in:
parent
6d38b057c1
commit
3dee8b73b9
2 changed files with 4 additions and 4 deletions
|
@ -19,7 +19,7 @@
|
||||||
"author": "Marc Cataford <c.marcandre@gmail.com>",
|
"author": "Marc Cataford <c.marcandre@gmail.com>",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"files": [
|
"files": [
|
||||||
"dist/**/*.ts"
|
"dist/*.ts"
|
||||||
],
|
],
|
||||||
"bin": "./dist/cli.js",
|
"bin": "./dist/cli.js",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
@ -32,7 +32,7 @@
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prebuild": "rimraf dist",
|
"prebuild": "rimraf dist",
|
||||||
"build": "babel src -d dist --extensions .ts",
|
"build": "babel src/index.ts src/cli.ts -d dist --extensions .ts",
|
||||||
"lint": "eslint src/**/*.ts",
|
"lint": "eslint src/**/*.ts",
|
||||||
"lint:fix": "yarn lint --fix",
|
"lint:fix": "yarn lint --fix",
|
||||||
"test": "jest src",
|
"test": "jest src",
|
||||||
|
|
|
@ -3,6 +3,8 @@ import { readFileSync } from 'fs'
|
||||||
|
|
||||||
import mockFS from 'mock-fs'
|
import mockFS from 'mock-fs'
|
||||||
|
|
||||||
|
import runPackwatch from '..'
|
||||||
|
|
||||||
jest.mock('child_process')
|
jest.mock('child_process')
|
||||||
|
|
||||||
function getPackOutput({ packageSize, unpackedSize }) {
|
function getPackOutput({ packageSize, unpackedSize }) {
|
||||||
|
@ -26,8 +28,6 @@ npm notice
|
||||||
`
|
`
|
||||||
}
|
}
|
||||||
|
|
||||||
import runPackwatch from '.'
|
|
||||||
|
|
||||||
function getManifest() {
|
function getManifest() {
|
||||||
try {
|
try {
|
||||||
return JSON.parse(readFileSync('.packwatch.json', { encoding: 'utf8' }))
|
return JSON.parse(readFileSync('.packwatch.json', { encoding: 'utf8' }))
|
Reference in a new issue