liveBook · Manning

Mockito

Mockito is a Java mocking framework for creating and configuring test doubles and verifying their interactions with dependencies.

How 2 Manning books explain it

Quarkus in Action

Mockito is a Java mocking framework for creating test doubles and specifying their behavior dynamically.

How it is used
Isolates Quarkus application tests from costly, unavailable, slow, or remote collaborators.
How deep it goes
Explains dynamic mock creation, configured behavior, CDI installation, scope limits, and native-mode constraints.
Examples
Uses a mocked GraphQLInventoryClient that returns one Peugeot during an availability-and-reservation test.
What you can do after
Apply it via QuarkusMock and Mockito DSL to isolate collaborators while testing application behavior.

Read how Quarkus in Action explains Mockito →

Kafka for Architects

Mockito is a Java mocking framework for creating and configuring test doubles that substitute for real dependencies.

How it is used
Isolates Kafka-backed services during lightweight unit tests by replacing networked producers and consumers with mock dependencies.
How deep it goes
Defines mock substitution and behavioral verification, but stops short of detailed Mockito APIs or implementation walkthroughs.
Examples
Uses ProfileService, Customer360Service, mocked Kafka components, return values, producer calls, and downstream side effects.
What you can do after
Apply via Mockito to test Kafka-backed service behavior without a Kafka cluster or real network communication.

Read how Kafka for Architects explains Mockito →

Related concepts

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.