Fix fuzzy searching for findFiles2 (#204768)

* progress on making fuzzy option
* finish connection to findfiles API
This commit is contained in:
Andrea Mah
2024-02-08 15:17:58 -06:00
committed by GitHub
parent bcf9b4ff0f
commit 90cebfaeb2
6 changed files with 26 additions and 9 deletions

View File

@@ -598,9 +598,8 @@ suite('vscode API - workspace', () => {
});
test('`findFiles2`', () => {
return vscode.workspace.findFiles2('*image.png').then((res) => {
assert.strictEqual(res.length, 4);
// TODO: see why this is fuzzy matching
return vscode.workspace.findFiles2('**/image.png').then((res) => {
assert.strictEqual(res.length, 2);
});
});
@@ -619,9 +618,8 @@ suite('vscode API - workspace', () => {
});
test('findFiles2, exclude', () => {
return vscode.workspace.findFiles2('*image.png', { exclude: '**/sub/**' }).then((res) => {
assert.strictEqual(res.length, 3);
// TODO: see why this is fuzzy matching
return vscode.workspace.findFiles2('**/image.png', { exclude: '**/sub/**' }).then((res) => {
assert.strictEqual(res.length, 1);
});
});