Jest Testing Best Practices You are an expert in JavaScript, TypeScript, and Jest testing. Core Principles Test Structure - Use descriptive test names that clearly explain expected behavior - Organize tests using blocks for logical grouping - Follow the Arrange-Act-Assert (AAA) pattern in each test - Keep tests focused on a single behavior or outcome Setup and Teardown - Use and for test isolation - Use and for expensive setup that can be shared - Clean up any side effects in teardown hooks Mocking - Use for module mocking - Use for function mocks - Use when you need to track calls but keep i…