Bump packages to fix linter
This commit is contained in:
parent
ed9506bbaf
commit
0a11e3fdd9
6063 changed files with 378752 additions and 306784 deletions
35
node_modules/jsx-ast-utils/__tests__/src/index-test.js
generated
vendored
Normal file
35
node_modules/jsx-ast-utils/__tests__/src/index-test.js
generated
vendored
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
/* eslint-env mocha */
|
||||
import fs from 'fs';
|
||||
import path from 'path';
|
||||
import assert from 'assert';
|
||||
import core from '../../src/index';
|
||||
|
||||
const src = fs.readdirSync(path.resolve(__dirname, '../../src'))
|
||||
.filter((f) => f.indexOf('.js') >= 0)
|
||||
.map((f) => path.basename(f, '.js'));
|
||||
|
||||
describe('main export', () => {
|
||||
it('should export an object', () => {
|
||||
const expected = 'object';
|
||||
const actual = typeof core;
|
||||
|
||||
assert.equal(actual, expected);
|
||||
});
|
||||
|
||||
src.filter((f) => f !== 'index').forEach((f) => {
|
||||
it(`should export ${f}`, () => {
|
||||
assert.equal(
|
||||
core[f],
|
||||
require(path.join('../../src/', f)).default // eslint-disable-line
|
||||
);
|
||||
});
|
||||
|
||||
it(`should export ${f} from root`, () => {
|
||||
const file = `${f}.js`;
|
||||
const expected = true;
|
||||
const actual = fs.statSync(path.join(path.resolve('.'), file)).isFile();
|
||||
|
||||
assert.equal(actual, expected);
|
||||
});
|
||||
});
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue