chore: create new tests for the UI, namely normnode, and one for all nodes
This commit is contained in:
@@ -127,10 +127,10 @@ describe("Logging component", () => {
|
||||
|
||||
render(<Logging/>);
|
||||
|
||||
expect(screen.getByText("Logs")).toBeInTheDocument();
|
||||
expect(screen.getByText("WARNING")).toBeInTheDocument();
|
||||
expect(screen.getByText("logging")).toBeInTheDocument();
|
||||
expect(screen.getByText("Ping")).toBeInTheDocument();
|
||||
expect(screen.getByText("Logs")).toBeDefined();
|
||||
expect(screen.getByText("WARNING")).toBeDefined();
|
||||
expect(screen.getByText("logging")).toBeDefined();
|
||||
expect(screen.getByText("Ping")).toBeDefined();
|
||||
|
||||
let timestamp = screen.queryByText("ABS TIME");
|
||||
if (!timestamp) {
|
||||
@@ -141,7 +141,7 @@ describe("Logging component", () => {
|
||||
}
|
||||
|
||||
await user.click(timestamp);
|
||||
expect(screen.getByText("00:00:12.345")).toBeInTheDocument();
|
||||
expect(screen.getByText("00:00:12.345")).toBeDefined();
|
||||
});
|
||||
|
||||
it("shows the scroll-to-bottom button after a manual scroll and scrolls when clicked", async () => {
|
||||
@@ -188,7 +188,7 @@ describe("Logging component", () => {
|
||||
logCell.set({...current, message: "Updated"});
|
||||
});
|
||||
|
||||
expect(screen.getByText("Updated")).toBeInTheDocument();
|
||||
expect(screen.getByText("Updated")).toBeDefined();
|
||||
await waitFor(() => {
|
||||
expect(scrollSpy).toHaveBeenCalledTimes(1);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user