vitest

Installation
SKILL.md

For E2E tests: Use prowler-test-ui skill (Playwright). This skill covers unit/integration tests with Vitest + React Testing Library.

Test Structure (REQUIRED)

Use Given/When/Then (AAA) pattern with comments:

it("should update user name when form is submitted", async () => {
  // Given - Arrange
  const user = userEvent.setup();
  const onSubmit = vi.fn();
  render(<UserForm onSubmit={onSubmit} />);

  // When - Act
  await user.type(screen.getByLabelText(/name/i), "John");
  await user.click(screen.getByRole("button", { name: /submit/i }));
Installs
62
GitHub Stars
14.0K
First Seen
Feb 18, 2026
vitest — prowler-cloud/prowler