Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions src/App.test.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
import { render, screen } from "@testing-library/react";
import { render } from "@testing-library/react";
import App from "./App";

test("renders without crashing", () => {
render(<App />);
});

test("renders main content", () => {
render(<App />);
const { container } = render(<App />);
// Verifica che l'app si renderizzi correttamente
const appElement = document.querySelector(".App") || document.body;
expect(appElement).toBeInTheDocument();
expect(container).toBeInTheDocument();
});

test("app contains content", () => {
const { container } = render(<App />);
// Verifica che ci sia del contenuto nel DOM
expect(container.firstChild).toBeTruthy();

Check failure on line 17 in src/App.test.js

View workflow job for this annotation

GitHub Actions / Lint Code

Avoid direct Node access. Prefer using the methods from Testing Library
});
Loading