提交 b26f6b25 编写于 作者: B Benjamin Pasero

fix tests

上级 fffb170c
......@@ -829,7 +829,7 @@ suite('Disk File Service', () => {
setTimeout(() => renameSync(toWatch.fsPath, toWatchRenamed.fsPath), 50);
});
test('watch - file - rename file (same case)', done => {
test('watch - file - rename file (different case)', done => {
const toWatch = URI.file(join(testDir, 'index-watch1.html'));
const toWatchRenamed = URI.file(join(testDir, 'INDEX-watch1.html'));
writeFileSync(toWatch.fsPath, 'Init');
......@@ -947,7 +947,7 @@ suite('Disk File Service', () => {
setTimeout(() => renameSync(file.fsPath, fileRenamed.fsPath), 50);
});
test('watch - folder (non recursive) - rename file (different casing)', done => {
test('watch - folder (non recursive) - rename file (different case)', done => {
const watchDir = URI.file(join(testDir, 'watch8'));
mkdirSync(watchDir.fsPath);
......@@ -956,7 +956,11 @@ suite('Disk File Service', () => {
const fileRenamed = URI.file(join(watchDir.fsPath, 'INDEX.html'));
assertWatch(watchDir, [[FileChangeType.DELETED, file], [FileChangeType.ADDED, fileRenamed]], done);
if (isLinux) {
assertWatch(watchDir, [[FileChangeType.DELETED, file], [FileChangeType.ADDED, fileRenamed]], done);
} else {
assertWatch(watchDir, [[FileChangeType.UPDATED, file]], done); // case insensitive file system treat this as change
}
setTimeout(() => renameSync(file.fsPath, fileRenamed.fsPath), 50);
});
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册