提交 0110d495 编写于 作者: B Benjamin Pasero

fix tests on windows

上级 9066eedc
......@@ -26,8 +26,8 @@ suite('Workspace', () => {
ws = new Workspace('id', 'name', roots, config);
assert.equal(ws.roots.length, 2);
assert.equal(ws.roots[0].fsPath, join(dirname(config.fsPath), roots[0].fsPath));
assert.equal(ws.roots[1].fsPath, join(dirname(config.fsPath), roots[1].fsPath));
assert.equal(ws.roots[0].fsPath, URI.file(join(dirname(config.fsPath), roots[0].fsPath)).fsPath);
assert.equal(ws.roots[1].fsPath, URI.file(join(dirname(config.fsPath), roots[1].fsPath)).fsPath);
// Absolute (from root)
config = URI.file('/workspace.code-workspace');
......@@ -35,7 +35,7 @@ suite('Workspace', () => {
ws = new Workspace('id', 'name', roots, config);
assert.equal(ws.roots.length, 2);
assert.equal(ws.roots[0].fsPath, join(dirname(config.fsPath), roots[0].fsPath));
assert.equal(ws.roots[1].fsPath, join(dirname(config.fsPath), roots[1].fsPath));
assert.equal(ws.roots[0].fsPath, URI.file(join(dirname(config.fsPath), roots[0].fsPath)).fsPath);
assert.equal(ws.roots[1].fsPath, URI.file(join(dirname(config.fsPath), roots[1].fsPath)).fsPath);
});
});
\ No newline at end of file
......@@ -108,7 +108,7 @@ suite('WorkspacesMainService', () => {
fs.writeFileSync(workspace.configPath, JSON.stringify({ folders: [{ path: './ticino-playground/lib' }] }));
const resolved = service.resolveWorkspaceSync(workspace.configPath);
assert.equal(resolved.folders[0].path, URI.file(path.join(path.dirname(workspace.configPath), 'ticino-playground', 'lib')).fsPath);
assert.equal(URI.file(resolved.folders[0].path).fsPath, URI.file(path.join(path.dirname(workspace.configPath), 'ticino-playground', 'lib')).fsPath);
done();
});
......@@ -119,7 +119,7 @@ suite('WorkspacesMainService', () => {
fs.writeFileSync(workspace.configPath, JSON.stringify({ folders: [{ path: './ticino-playground/lib/../other' }] }));
const resolved = service.resolveWorkspaceSync(workspace.configPath);
assert.equal(resolved.folders[0].path, URI.file(path.join(path.dirname(workspace.configPath), 'ticino-playground', 'other')).fsPath);
assert.equal(URI.file(resolved.folders[0].path).fsPath, URI.file(path.join(path.dirname(workspace.configPath), 'ticino-playground', 'other')).fsPath);
done();
});
......@@ -130,7 +130,7 @@ suite('WorkspacesMainService', () => {
fs.writeFileSync(workspace.configPath, JSON.stringify({ folders: [{ path: 'ticino-playground/lib' }] }));
const resolved = service.resolveWorkspaceSync(workspace.configPath);
assert.equal(resolved.folders[0].path, URI.file(path.join(path.dirname(workspace.configPath), 'ticino-playground', 'lib')).fsPath);
assert.equal(URI.file(resolved.folders[0].path).fsPath, URI.file(path.join(path.dirname(workspace.configPath), 'ticino-playground', 'lib')).fsPath);
done();
});
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册