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

Bump dependencies #93

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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 __tests__/budgets-analyzer.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* https://opensource.org/licenses/MIT
*/

const analyzeBudgets = require('../lib/budgets-analyzer');
const analyzeBudgets = require('../lib/budgets-analyzer.js');

describe('budgets-analyzer', () => {
const processExit = process.exit;
Expand Down
2 changes: 1 addition & 1 deletion __tests__/helpers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const {
getOwnProps,
convertToBudgetList,
convertToResourceKey,
} = require('../lib/helpers');
} = require('../lib/helpers.js');

jest.mock('rimraf');
jest.mock('mkdirp');
Expand Down
2 changes: 1 addition & 1 deletion __tests__/reporter.test.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const writeReport = require('../lib/lighthouse-reporter');
const writeReport = require('../lib/lighthouse-reporter.js');

describe('Reporter', () => {
jest.setTimeout(20000); // Allows more time to run all tests
Expand Down
2 changes: 1 addition & 1 deletion __tests__/score-analyzer.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* https://opensource.org/licenses/MIT
*/

const analyzeScore = require('../lib/score-analyzer');
const analyzeScore = require('../lib/score-analyzer.js');

describe('score-analyzer', () => {
const processExit = process.exit;
Expand Down
6 changes: 3 additions & 3 deletions bin/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ const chalk = require('chalk');
const updateNotifier = require('update-notifier');
const pkg = require('../package.json');

const { getChromeFlags } = require('../lib/config');
const lighthouseReporter = require('../lib/lighthouse-reporter');
const { calculateResults } = require('../lib/calculate-results');
const { getChromeFlags } = require('../lib/config.js');
const lighthouseReporter = require('../lib/lighthouse-reporter.js');
const { calculateResults } = require('../lib/calculate-results.js');

const spinner = ora({
color: 'yellow',
Expand Down
8 changes: 4 additions & 4 deletions lib/calculate-results.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* https://opensource.org/licenses/MIT
*/

const { scoreReducer } = require('./helpers');
const analyzeScore = require('./score-analyzer');
const analyzeBudgets = require('./budgets-analyzer');
const { getScores } = require('./config');
const { scoreReducer } = require('./helpers.js');
const analyzeScore = require('./score-analyzer.js');
const analyzeBudgets = require('./budgets-analyzer.js');
const { getScores } = require('./config.js');

const calculateResults = (flags, categoryReport, budgetsReport, failOnBudgets) => {
let thresholds = scoreReducer(flags, getScores());
Expand Down
12 changes: 6 additions & 6 deletions lib/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ const rimraf = require('rimraf');

const clean = () =>
new Promise((resolve, reject) => {
rimraf('./lighthouse/', (err) => {
if (err) {
return reject(err);
rimraf('./lighthouse/', (error) => {
if (error) {
return reject(error);
}

return resolve();
Expand All @@ -21,9 +21,9 @@ const clean = () =>

const createDir = () =>
new Promise((resolve, reject) => {
mkdirp('./lighthouse', (err) => {
if (err) {
return reject(err);
mkdirp('./lighthouse', (error) => {
if (error) {
return reject(error);
}

return resolve();
Expand Down
2 changes: 1 addition & 1 deletion lib/lighthouse-reporter.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const lighthouse = require('lighthouse');
const chromeLauncher = require('chrome-launcher');
const ReportGenerator = require('lighthouse/report/generator/report-generator');
const chalk = require('chalk');
const { createDefaultConfig, getOwnProps, convertToBudgetList, convertToResourceKey } = require('./helpers');
const { createDefaultConfig, getOwnProps, convertToBudgetList, convertToResourceKey } = require('./helpers.js');

const readFile = promisify(fs.readFile);

Expand Down
Loading