concept some confidence in category javascript

appears as: some confidence
Testing JavaScript Applications

This is an excerpt from Manning's book Testing JavaScript Applications.

Listing 7.38. App.test.jsx
import { render, waitFor } from "@testing-library/react";

// ...

test("rendering the server's list of items", async () => {
  const { getByText } = render(<App />);  #1

  await waitFor(() => {  #2
    const listElement = document.querySelector("ul");
    expect(listElement.childElementCount).toBe(3);
  });

  expect(getByText("cheesecake - Quantity: 2"))  #3
    .toBeInTheDocument();
  expect(getByText("croissant - Quantity: 5"))  #4
    .toBeInTheDocument();
  expect(getByText("macaroon - Quantity: 96"))  #5
    .toBeInTheDocument();
});