hectoday
DocsCoursesChangelog GitHub
DocsCoursesChangelog GitHub

Access Required

Enter your access code to view courses.

Invalid code

← All courses

Testing APIs with @hectoday/http

Write tests that catch bugs before users do. Unit tests for pure functions, integration tests for route handlers, test databases, factories, mocking external services, and testing edge cases — all with Vitest and Hectoday HTTP.

Intermediate ~5 hours

Why Test

  1. What Testing Gives You
  2. Types of Tests
  3. Project Setup

Unit Testing

  1. Testing Pure Functions
  2. Testing Zod Schemas
  3. Testing Business Logic

Integration Testing

  1. Testing Route Handlers
  2. Testing GET Endpoints
  3. Testing POST Endpoints
  4. Testing Error Responses
  5. Testing Authentication

Test Helpers

  1. Factories and Fixtures
  2. Test Database Isolation
  3. Request Helpers

Advanced Testing

  1. Mocking External Services
  2. Testing Background Jobs
  3. Testing Edge Cases

Putting It All Together

  1. Test Organization
  2. Checklist and Capstone

© 2026 hectoday. All rights reserved.