Beyond the unit/integration/E2E tiers, several specialized testing strategies target specific risks. Regression testing re-runs existing suites after changes to catch unintended side effects and is often automated in CI/CD pipelines. It can be performed as a full regression, running every test; as a selective regression, running only tests related to the modified code; or as a risk-based regression, prioritizing tests for the most critical features. Smoke testing, also called build verification testing, is a quick, shallow check that the most critical functions still work, answering the question of whether the build even boots before deeper testing begins. Sanity testing is a narrower, deeper check performed after a specific change to confirm that a particular bug fix or feature behaves correctly. Smoke is therefore broad and shallow, while sanity is narrow and deep.
Performance testing evaluates how a system behaves under various conditions. Load testing simulates expected concurrent users or requests to verify the system meets its performance baselines in response time, throughput, and error rates. Stress testing pushes the system beyond its normal capacity, while spike testing introduces sudden large load increases. Endurance testing, sometimes called soak testing, applies sustained load over an extended period to expose issues like memory leaks. Tools such as JMeter, k6, Gatling, and Locust enable these scenarios.
Flaky tests are a persistent operational headache. They pass or fail intermittently without any change to the code, often because of shared mutable state, timing or race conditions in async code, external dependency failures, or order-dependent assertions. CI/CD teams handle flaky tests by quarantining them into separate suites that do not block deployments, configuring retries for transient failures, tracking their history to find patterns, and ultimately fixing root causes rather than masking them with retries. A coherent CI/CD testing strategy runs the fastest tests first: pre-commit hooks perform linting and unit tests for immediate developer feedback; the CI build runs unit and integration tests; staging executes E2E and smoke tests; pre-deploy runs contract tests and security scans; and post-deploy uses smoke tests and synthetic monitoring. The underlying principle, often called shift left, is to catch bugs as early as possible because a defect found in development costs roughly an order of magnitude less to fix than one discovered in production.