Skip to content

Commit

Permalink
benchmark: fix platform in basename-win32
Browse files Browse the repository at this point in the history
It should say `win32` and not `posix`.

PR-URL: nodejs#18320
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
BridgeAR authored and ryzokuken committed Jun 6, 2018
1 parent 4b2792a commit 16a3c7c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions benchmark/path/basename-win32.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use strict';
const common = require('../common.js');
const path = require('path');
const { win32 } = require('path');

const bench = common.createBenchmark(main, {
pathext: [
Expand All @@ -20,7 +20,6 @@ const bench = common.createBenchmark(main, {

function main(conf) {
const n = +conf.n;
const p = path.win32;
var input = String(conf.pathext);
var ext;
const extIdx = input.indexOf('|');
Expand All @@ -31,7 +30,7 @@ function main(conf) {

bench.start();
for (var i = 0; i < n; i++) {
p.basename(input, ext);
win32.basename(pathext, ext);
}
bench.end(n);
}

0 comments on commit 16a3c7c

Please sign in to comment.