Skip to content

Commit 161a389

Browse files
committed
More fixes
1 parent 091b0ea commit 161a389

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/test/datascience/notebook/helper.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,9 @@ export async function insertMarkdownCell(source: string) {
6161
]);
6262

6363
await waitForCondition(
64-
async () => activeEditor?.document.cells[0].document.getText().trim() === source.trim(),
64+
async () =>
65+
activeEditor?.document.cells[activeEditor.document.cells.length - 1].document.getText().trim() ===
66+
source.trim(),
6567
5_000,
6668
'Cell not inserted'
6769
);
@@ -83,7 +85,9 @@ export async function insertPythonCell(source: string) {
8385
}
8486
]);
8587
await waitForCondition(
86-
async () => activeEditor?.document.cells[0].document.getText().trim() === source.trim(),
88+
async () =>
89+
activeEditor?.document.cells[activeEditor.document.cells.length - 1].document.getText().trim() ===
90+
source.trim(),
8791
5_000,
8892
'Cell not inserted'
8993
);

0 commit comments

Comments
 (0)