Skip to content

Commit 90c19ef

Browse files
committed
appveyor e2e
1 parent 4844e7e commit 90c19ef

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

addon/ng2/models/find-lazy-modules.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -57,12 +57,15 @@ export function findLazyModules(projectRoot: any): string[] {
5757
findLoadChildren(tsPath).forEach(moduleName => {
5858
const fileName = path.resolve(path.dirname(tsPath), moduleName) + '.ts';
5959
if (fs.existsSync(fileName)) {
60-
// Put the moduleName as relative to the main.ts.
60+
// Convert the file path to a url.
6161
const posix = path.posix;
62-
const normalizedPath = posix.normalize(tsPath);
63-
const nomalizedModuleName = posix.normalize(moduleName);
64-
const fullPath = posix.resolve(posix.dirname(normalizedPath), nomalizedModuleName);
65-
const name = `./${posix.relative(projectRoot, fullPath)}.ts`;
62+
const normalizedPath = tsPath.replace(/\\/g, posix.sep);
63+
const normalizedModuleName = moduleName.replace(/\\/g, posix.sep);
64+
const normalizedProjectRoot = projectRoot.replace(/\\/g, posix.sep);
65+
66+
// Put the moduleName as relative to the main.ts.
67+
const fullPath = posix.resolve(posix.dirname(normalizedPath), normalizedModuleName);
68+
const name = `./${posix.relative(normalizedProjectRoot, fullPath)}.ts`;
6669
result[name] = true;
6770
}
6871
});

tests/e2e/utils/git.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ export function expectGitToBeClean() {
2626
});
2727
}
2828

29-
3029
export function gitCommit(message: string) {
3130
return git('add', '-A')
3231
.then(() => git('status', '--porcelain'))

0 commit comments

Comments
 (0)