Unit Test Scheduled Async

Provides patterns for unit testing Spring `@Scheduled` and `@Async` methods using JUnit 5, CompletableFuture, Awaitility, and Mockito. Covers mocking task execution and timing, verifying execution counts, testing cron expressions, validating retry behavior, and simulating thread pool behavior. Use when testing background tasks, cron jobs, periodic execution, scheduled tasks, or thread pool behavior.

giuseppe-trisciuoglio Updated 371 repo stars
Picture from the README

File contents

giuseppe-trisciuoglio/developer-kit commit d14439224d

Frequently asked questions

npx get-skill add giuseppe-trisciuoglio/unit-test-scheduled-async