Skip to content

Commit

Permalink
tests: use relative path in utils test files (#737)
Browse files Browse the repository at this point in the history
  • Loading branch information
connorjclark committed Jul 18, 2022
1 parent 0da6496 commit 908b075
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions packages/utils/test/assertions.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@

/* eslint-env jest */

const lighthouseAllPreset = require('@lhci/utils/src/presets/all.js');
const {convertBudgetsToAssertions} = require('@lhci/utils/src/budgets-converter.js');
const {getAllAssertionResults} = require('@lhci/utils/src/assertions.js');
const lighthouseAllPreset = require('../src/presets/all.js');
const {convertBudgetsToAssertions} = require('../src/budgets-converter.js');
const {getAllAssertionResults} = require('../src/assertions.js');

describe('getAllAssertionResults', () => {
let lhrs;
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/test/audit-diff-finder.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const {
synthesizeItemKeyDiffs,
sortZippedBaseAndCompareItems,
replaceNondeterministicStrings,
} = require('@lhci/utils/src/audit-diff-finder.js');
} = require('../src/audit-diff-finder.js');

describe('#findAuditDiffs', () => {
it('should return empty array for identical audits', () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/test/budgets-converter.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
const {
convertPathExpressionToRegExp,
convertBudgetsToAssertions,
} = require('@lhci/utils/src/budgets-converter.js');
} = require('../src/budgets-converter.js');

describe('convertPathExpressionToRegExp', () => {
const pathMatch = (path, pattern) => {
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/test/saved-reports.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
const fs = require('fs');
const path = require('path');
const {withTmpDir} = require('../../cli/test/test-utils.js');
const {replaceUrlPatterns, saveLHR} = require('@lhci/utils/src/saved-reports.js');
const {replaceUrlPatterns, saveLHR} = require('../src/saved-reports.js');

describe('#replaceUrlPatterns', () => {
it('should replace basic patterns', () => {
Expand Down

0 comments on commit 908b075

Please sign in to comment.