Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from homer0/homer0_jsdoc
Remove ESDoc and Jest-Ex
- Loading branch information
Showing
11 changed files
with
435 additions
and
1,922 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = { | ||
automock: true, | ||
collectCoverage: true, | ||
testPathIgnorePatterns: ['/node_modules/', '/utils/scripts/'], | ||
unmockedModulePathPatterns: ['/node_modules/'], | ||
testEnvironment: 'node', | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
const packageJson = require('./package.json'); | ||
|
||
module.exports = { | ||
source: { | ||
include: ['./src'], | ||
includePattern: '.js$', | ||
}, | ||
plugins: [ | ||
'docdash/nativeTypesPlugin', | ||
'plugins/markdown', | ||
], | ||
templates: { | ||
cleverLinks: true, | ||
default: { | ||
includeDate: false, | ||
}, | ||
}, | ||
opts: { | ||
recurse: true, | ||
destination: './docs', | ||
readme: 'README.md', | ||
template: 'node_modules/docdash', | ||
}, | ||
docdash: { | ||
title: packageJson.name, | ||
meta: { | ||
title: `${packageJson.name} docs`, | ||
}, | ||
sectionOrder: [], | ||
collapse: true, | ||
refLinks: [ | ||
{ | ||
title: 'View the package on Yarn', | ||
url: `https://yarnpkg.com/package/${packageJson.name}`, | ||
type: 'yarn', | ||
}, | ||
{ | ||
title: 'Go to the GitHub repository', | ||
url: `https://github.com/${packageJson.repository}`, | ||
type: 'github', | ||
}, | ||
{ | ||
title: 'View the package on NPM', | ||
url: `https://www.npmjs.com/package/${packageJson.name}`, | ||
type: 'npm', | ||
}, | ||
], | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,2 @@ | ||
#!/bin/bash -e | ||
esdoc -c .esdoc.json | ||
rm -rf docs/package.json | ||
jsdoc -c .jsdoc.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,2 @@ | ||
#!/bin/bash -e | ||
files=$(git status -s | grep -E '[AM?]+\s.+?\.(js|jsx)$' | cut -c3-) | ||
|
||
# Prevent ESLint from running if there are no files | ||
if [[ $files = "" ]] ; then | ||
exit 0 | ||
fi | ||
|
||
eslint ${files} --no-ignore; | ||
lint-staged |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,2 @@ | ||
#!/usr/bin/env node | ||
|
||
const { JestExRunner } = require('jest-ex'); | ||
const { Logger } = require('wootils/node/logger'); | ||
const packageInfo = require('../../package.json'); | ||
|
||
const logger = new Logger(packageInfo.name); | ||
|
||
new JestExRunner('./.jestrc.json', { | ||
addTransformer: true, | ||
addStubs: true, | ||
cache: false, | ||
runInParallel: false, | ||
}) | ||
.run() | ||
.then(() => logger.success('Yay! all the unit tests passed!')) | ||
.catch(() => { | ||
logger.error('Damn... something went wrong with the unit tests'); | ||
process.exit(1); | ||
}); | ||
#!/bin/bash -e | ||
jest -c ./.jestrc.js $@ |
Oops, something went wrong.