Types of Testing

Common Types

TypeQuestion it answersShopEase example
Functionaldoes the feature work as per the requirement?login with a valid email and password opens My Account
Regressiondid the new change break old features?after adding UPI payment, card payment still works
Smokeis the build stable enough to test at all?home page loads, login works, search returns results
Sanitydoes the one fixed area work now?the "cart count not updating" bug is fixed
UI testingare screens, buttons, messages right?the error message is shown in red under the form
API testingdo the backend endpoints return the right data?GET /api/products?q=shoes returns 200 and JSON
Cross-browserdoes it work in Chrome, Firefox, Edge, Safari?checkout works in Firefox too

Smoke vs Sanity

New build arrives
       |
       v
  SMOKE test  (wide and shallow: 10-20 key checks across the app)
       |  pass
       v
  Full testing / regression
       |
  Bug fix build arrives
       |
       v
  SANITY test (narrow and deep: only the fixed area and its neighbours)

Note: Selenium is a UI automation tool. It is used mostly for functional, smoke and regression testing through the browser. API tests use tools like REST Assured or Postman (covered in the advance level).