Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(lint): correct setup to require extension #381

Merged
merged 1 commit into from
Aug 6, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ module.exports = {
extends: ['algolia', 'algolia/jest'],
rules: {
'valid-jsdoc': 'off',
'import/extensions': ['error', 'ignorePackages'],
'import/extensions': ['error', 'always', { ignorePackages: true }],
},
};
2 changes: 1 addition & 1 deletion src/__tests__/changelog.test.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { getChangelogs, __RewireAPI__ } from '../changelog'; // eslint-disable-line import/named
import { getChangelogs, __RewireAPI__ } from '../changelog.js'; // eslint-disable-line import/named

const gotSnapshotUrls = new Set([
'https://gitlab.com/janslow/gitlab-fetch/raw/master/CHANGELOG.md',
Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/config.test.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import config from '../config';
import config from '../config.js';

it('gets the correct keys from env variables', () => {
// from mocked .env
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/formatPkg.test.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import formatPkg from '../formatPkg';
import formatPkg from '../formatPkg.js';
import rawPackages from './rawPackages.json';
import isISO8601 from 'validator/lib/isISO8601';
import isISO8601 from 'validator/lib/isISO8601.js';

it('transforms correctly', () => {
rawPackages
Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/typescript.test.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { getTypeScriptSupport } from '../typescriptSupport';
jest.mock('../npm');
jest.mock('../unpkg');
import { getTypeScriptSupport } from '../typescriptSupport.js';
import * as npm from '../npm/index.js';
import { fileExistsInUnpkg } from '../unpkg.js';

Expand Down