bbovenzi commented on code in PR #65039:
URL: https://github.com/apache/airflow/pull/65039#discussion_r3073537055
##########
airflow-core/src/airflow/ui/src/pages/TaskInstance/Logs/Logs.test.tsx:
##########
@@ -133,4 +133,38 @@ describe("Task log grouping", () => {
await waitFor(() => expect(screen.queryByText(/Marking task as
SUCCESS/iu)).not.toBeVisible());
}, 10_000);
+
+ it("Has sequential line numbers with no gaps or duplicates", async () => {
+ render(
+ <AppWrapper
initialEntries={["/dags/log_grouping/runs/manual__2025-02-18T12:19/tasks/generate"]}
/>,
+ );
+
+ await waitForLogs();
+
+ // Expand all groups so their content lines are in the DOM
+ const summaryPre = screen.getByTestId("summary-Pre task execution logs");
+
+ fireEvent.click(summaryPre);
+ await waitFor(() => expect(screen.getByText(/starting attempt 1 of
3/iu)).toBeVisible());
+
+ const summaryPost = screen.getByTestId("summary-Post task execution logs");
+
+ fireEvent.click(summaryPost);
+ await waitFor(() => expect(screen.queryByText(/Marking task as
SUCCESS/iu)).toBeVisible());
+
+ // Collect all rendered line number links
+ const lineNumbers =
[...document.querySelectorAll<HTMLAnchorElement>("a[id]")]
Review Comment:
This is looking across the whole document. Let's look only inside the Log
Code component
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]