Skip to content

Commit b29bada

Browse files
Trottcodebytere
authored andcommitted
benchmark: fix getStringWidth() benchmark
8fb5fe2 broke the benchmark for getStringWidth(). This fixes it up by updating the argument to `require()` to retrieve `getStringWidth()` from the new internal module location. PR-URL: #31476 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
1 parent 03aac4e commit b29bada

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

benchmark/misc/getstringwidth.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ const bench = common.createBenchmark(main, {
1212
function main({ n, type }) {
1313
// Default value for testing purposes.
1414
type = type || 'ascii';
15-
const { getStringWidth } = require('internal/readline/utils');
15+
const { getStringWidth } = require('internal/util/inspect');
1616

1717
const str = ({
1818
ascii: 'foobar'.repeat(100),

0 commit comments

Comments
 (0)