Skip to content

Commit 1cf4987

Browse files
authored
Round 7 (#569)
1 parent 9175cb1 commit 1cf4987

File tree

129 files changed

+186
-396
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

129 files changed

+186
-396
lines changed
File renamed without changes.

test/unit/NpmPackageJsonLint.test.js renamed to test/unit/NpmPackageJsonLint.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const NpmPackageJsonLint = require('../../src/NpmPackageJsonLint');
1+
import NpmPackageJsonLint from '../../src/NpmPackageJsonLint';
22

33
describe('NpmPackageJsonLint Unit Tests', () => {
44
describe('lint method', () => {

test/unit/Parser.test.js renamed to test/unit/Parser.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
const fs = require('fs');
2-
const Parser = require('../../src/Parser');
1+
import fs from 'fs';
2+
import Parser from '../../src/Parser';
33

44
jest.mock('fs');
55

test/unit/Reporter.test.js renamed to test/unit/Reporter.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
const chalk = require('chalk');
2-
const Reporter = require('../../src/Reporter');
1+
import chalk from 'chalk';
2+
import Reporter from '../../src/Reporter';
33

44
describe('Reporter Unit Tests', () => {
55
describe('write method', () => {

test/unit/Rules.test.js renamed to test/unit/Rules.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
const chalk = require('chalk');
2-
const fs = require('fs');
3-
const path = require('path');
4-
const Rules = require('../../src/Rules');
1+
import chalk from 'chalk';
2+
import fs from 'fs';
3+
import path from 'path';
4+
import Rules from '../../src/Rules';
55

66
jest.mock('fs');
77
jest.mock('path');

test/unit/api.test.js renamed to test/unit/api.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const api = require('../../src/api');
1+
import api from '../../src/api';
22

33
jest.mock('../../src/NpmPackageJsonLint');
44

test/unit/Config.test.js renamed to test/unit/config.test.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
const {cosmiconfigSync} = require('cosmiconfig');
2-
const Config = require('../../src/Config');
3-
const applyOverrides = require('../../src/config/applyOverrides');
4-
const applyExtendsIfSpecified = require('../../src/config/applyExtendsIfSpecified');
5-
const Rules = require('../../src/Rules');
1+
import {cosmiconfigSync} from 'cosmiconfig';
2+
import * as Config from '../../src/Config';
3+
import applyOverrides from '../../src/config/applyOverrides';
4+
import applyExtendsIfSpecified from '../../src/config/applyExtendsIfSpecified';
5+
import Rules from '../../src/Rules';
66

77
const rules = new Rules();
88
rules.load();

test/unit/config/ConfigValidator.test.js renamed to test/unit/config/ConfigValidator.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
const configValidator = require('../../../src/config/ConfigValidator');
2-
const Rules = require('../../../src/Rules');
1+
import configValidator from '../../../src/config/ConfigValidator';
2+
import Rules from '../../../src/Rules';
33

44
const rules = new Rules();
55
rules.load();

test/unit/config/applyExtendsIfSpecified.test.js renamed to test/unit/config/applyExtendsIfSpecified.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const applyExtendsIfSpecified = require('../../../src/config/applyExtendsIfSpecified');
1+
import applyExtendsIfSpecified from '../../../src/config/applyExtendsIfSpecified';
22

33
describe('applyExtendsIfSpecified Unit Tests', () => {
44
test('when file has local extends (valid - js), a config object is returned', () => {

test/unit/config/applyOverrides.test.js renamed to test/unit/config/applyOverrides.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
const path = require('path');
2-
const globby = require('globby');
3-
const applyOverrides = require('../../../src/config/applyOverrides');
1+
import path from 'path';
2+
import globby from 'globby';
3+
import applyOverrides from '../../../src/config/applyOverrides';
44

55
jest.mock('globby');
66
jest.mock('path');

0 commit comments

Comments
 (0)