fix(test): fix Jest tests (#77)

This commit is contained in:
Rajiv Shah 2019-11-28 02:41:47 -05:00 committed by nothingismagick
parent d1cd6d102e
commit 24a339ae75
3 changed files with 10 additions and 6 deletions

View File

@ -11,7 +11,8 @@ module.exports = {
collectCoverage: true,
coverageDirectory: '<rootDir>/test/jest/coverage',
collectCoverageFrom: [
'<rootDir>/mode/**/*.js'
'<rootDir>/bin/**/*.js',
'<rootDir>/helpers/**/*.js'
],
coverageReporters: ['json-summary', 'text', 'lcov'],
coverageThreshold: {
@ -29,8 +30,11 @@ module.exports = {
moduleFileExtensions: ['js', 'json'],
moduleNameMapper: {
'^~/(.*)$': '<rootDir>/$1',
'^mode/(.*)$': '<rootDir>/mode/$1',
'^test/(.*)$': '<rootDir>/test/$1'
'^bin/(.*)$': '<rootDir>/bin/$1',
'^helpers/(.*)$': '<rootDir>/helpers/$1',
'^templates/(.*)$': '<rootDir>/templates/$1',
'^test/(.*)$': '<rootDir>/test/$1',
'../../package.json': '<rootDir>/package.json'
},
transform: {}
}

View File

@ -1,4 +1,4 @@
const { tauri } = require('mode/bin/tauri')
const { tauri } = require('bin/tauri')
describe('[CLI] tauri.js', () => {
it('displays a help message', async () => {

View File

@ -1,5 +1,5 @@
const { tauricon } = require('mode/helpers/tauricon')
const { tauri } = require('mode/bin/tauri')
const { tauricon } = require('helpers/tauricon')
const { tauri } = require('bin/tauri')
describe('[CLI] tauri-icon internals', () => {
it('tells you the version', () => {