Skip to content
Closed
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 lib/cli/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*/

const debug = require("debug")("mocha:cli:cli");
const symbols = require("log-symbols");
const { default: symbols } = require("log-symbols");
const yargs = require("yargs");
const path = require("node:path");
const {
Expand Down
2 changes: 1 addition & 1 deletion lib/cli/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @private
*/

const symbols = require("log-symbols");
const { default: symbols } = require("log-symbols");
const pc = require("picocolors");
const Mocha = require("../mocha");
const {
Expand Down
2 changes: 1 addition & 1 deletion lib/cli/watch-run.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"use strict";

const logSymbols = require("log-symbols");
const { default: logSymbols } = require('log-symbols');
const debug = require("debug")("mocha:cli:watch");
const path = require("node:path");
const chokidar = require("chokidar");
Expand Down
2 changes: 1 addition & 1 deletion lib/reporters/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ var diff = require("diff");
var milliseconds = require("ms");
var utils = require("../utils");
var supportsColor = require("supports-color");
var symbols = require("log-symbols");
var { default: symbols } = require('log-symbols');
var constants = require("../runner").constants;
var EVENT_TEST_PASS = constants.EVENT_TEST_PASS;
var EVENT_TEST_FAIL = constants.EVENT_TEST_FAIL;
Expand Down
61 changes: 42 additions & 19 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@
"he": "^1.2.0",
"is-path-inside": "^3.0.3",
"js-yaml": "^4.1.0",
"log-symbols": "^4.1.0",
"log-symbols": "^7.0.1",
"minimatch": "^9.0.5",
"ms": "^2.1.3",
"picocolors": "^1.1.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
import path from 'path'
import {fileURLToPath} from 'url'

/**
* @param {string} specifier
* @param {{
Expand All @@ -11,8 +8,5 @@ import {fileURLToPath} from 'url'
* @returns {Promise<{ url: string }>}
*/
export async function resolve(specifier, context, defaultResolve) {
const extension = path.extname(
fileURLToPath(/**@type {import('url').URL}*/ (new URL(specifier, context.parentURL))),
)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This code is unused and causes a different error on main vs. this branch. Same with #5482. 🔪

return await defaultResolve(specifier.replace('.ts', '.mjs'), context, defaultResolve)
}
Loading