How to Jest Snapshot Test the Difference
A tutorial on using Jest snapshot testing to capture and compare the output of a React component before and after a state change.
A tutorial on using Jest snapshot testing to capture and compare the output of a React component before and after a state change.
The article argues against writing many small, single-assertion tests for React components, advocating for fewer, more comprehensive tests.
A tutorial on setting up and using Enzyme with Jest for unit and integration testing of React components.
Explains why nesting in tests, especially with beforeEach hooks, leads to unmaintainable code, using a React component as an example.
A tutorial on using Dependency Injection to mock network services in iOS View Controllers for better testability and separation of concerns.
A tutorial on unit testing an ASP.NET Core Web API controller using XUnit and FakeItEasy, covering mocking dependencies and test structure.
A tutorial on applying Test-Driven Development (TDD) principles to build and test a Vue.js component, using a color picker as an example.
A guide to testing iOS view controller navigation using a NavigationDelegate pattern to simplify unit tests and avoid complex UI setups.
A guide to writing better unit tests for delegate patterns in Swift/iOS, focusing on behavior over implementation for maintainable test suites.
Explains NSpec conventions for BDD testing in .NET, covering context, setup, assertions, and cleanup.
Argues that code coverage is a flawed metric for software quality, comparing it to IQ tests, and demonstrates its limitations with examples.
A guide to writing unit tests that ensure ASP.NET MVC action methods have the ValidateAntiForgeryToken attribute, with tips for the ReSharper/Rider test runner.
Explains the different types of test doubles (dummies, fakes, stubs, spies) in Swift for unit testing, with code examples.
A guide to improving Swift code maintainability and testability by separating decision logic from action logic using the type system.
Explores why skilled developers write poor unit tests by misapplying production code principles, arguing test code should prioritize clarity over abstraction.
A guide to removing code duplication in Swift unit tests by creating reusable helper functions, improving test suite maintainability.
Explains how to use test fixtures in Swift to simplify unit test setup, making code cleaner and more focused.
An article explaining the fundamentals of software testing, from basic assertions to advanced frameworks, and how to build your own testing tools.
Explores common developer struggles with writing and maintaining tests, and offers practical advice to overcome these challenges.
A tutorial on unit testing a Vue.js component using Vue Test Utils and Jest, covering setup, best practices, and test implementation.