Skip to content

Commit bf1c988

Browse files
hanslalexeagle
authored andcommitted
test: fix windows path issues
1 parent 49ba744 commit bf1c988

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

scripts/test.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@ import * as Istanbul from 'istanbul';
1313
import 'jasmine';
1414
import { SpecReporter as JasmineSpecReporter } from 'jasmine-spec-reporter';
1515
import { ParsedArgs } from 'minimist';
16-
import { join, relative } from 'path';
16+
import { join, normalize, relative } from 'path';
1717
import { Position, SourceMapConsumer } from 'source-map';
1818
import * as ts from 'typescript';
1919
import { packages } from '../lib/packages';
20-
import { diff } from 'semver';
2120

2221
const codeMap = require('../lib/istanbul-local').codeMap;
2322
const Jasmine = require('jasmine');
@@ -233,7 +232,9 @@ export default function (args: ParsedArgs, logger: logging.Logger) {
233232
// And add the current status to it (so it takes the non-committed changes).
234233
..._exec('git', ['status', '--short', '--show-stash'], {}, logger)
235234
.split('\n').map(x => x.slice(2).trim()),
236-
].filter(x => x !== '');
235+
]
236+
.map(x => normalize(x))
237+
.filter(x => x !== '.' && x !== ''); // Empty paths will be normalized to dot.
237238

238239
const diffPackages = new Set();
239240
for (const pkgName of Object.keys(packages)) {

0 commit comments

Comments
 (0)