Skip to content

Commit 7e942c6

Browse files
committed
[AI] Update tests
1 parent c790e07 commit 7e942c6

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/test/unittest/noConfigDebugInit.unit.test.ts

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ suite('setup for no-config debug scenario', function () {
1919
let context: TypeMoq.IMock<IExtensionContext>;
2020
let noConfigScriptsDir: string;
2121
let bundledDebugPath: string;
22-
let DEBUGPY_ADAPTER_ENDPOINTS = 'DEBUGPY_ADAPTER_ENDPOINTS';
22+
let DEBUGPY_ADAPTER_ENDPOINTS = 'VSCODE_DEBUGPY_ADAPTER_ENDPOINTS';
2323
let BUNDLED_DEBUGPY_PATH = 'BUNDLED_DEBUGPY_PATH';
2424
let workspaceUriStub: sinon.SinonStub;
2525

@@ -193,10 +193,12 @@ suite('setup for no-config debug scenario', function () {
193193

194194
// Assert
195195
sinon.assert.calledOnce(createFileSystemWatcherFunct);
196-
const expectedPattern = new RelativePattern(
197-
path.join(os.tmpdir(), '.noConfigDebugAdapterEndpoints'),
198-
'**/*.txt',
199-
);
196+
const expectedPattern = sinon
197+
.match.instanceOf(RelativePattern)
198+
.and(
199+
sinon.match.has('base', path.join(os.tmpdir(), '.noConfigDebugAdapterEndpoints')),
200+
)
201+
.and(sinon.match.has('pattern', sinon.match(/^endpoint-[0-9a-f]{16}\.txt$/)));
200202
sinon.assert.calledWith(createFileSystemWatcherFunct, expectedPattern);
201203
});
202204

0 commit comments

Comments
 (0)