[Go to site: main page, start]

Java Mocking

Open-source Java projects categorized as Mocking

Top 11 Java Mocking Projects

  1. Mockito

    Most popular Mocking framework for unit tests written in Java

    Project mention: Stepping down as Mockito maintainer after 10 years | news.ycombinator.com | 2025-12-28

    > Is there a point at which library maintainer feedback would meaningfully influence a by-default JVM change?

    Of course, just keep in mind that all these changes were and are being done in response to feedback from others. When you have such a large ecosystem, users can have contradictory demands and sometimes it's impossible to satisfy everyone simultaneously. In those cases, we try to choose whatever we think will do the most good and the least harm over the entire ecosystem.

    > JPMS is a good example: --add-opens still remains valuable today for important infra like Hadoop, Spark, and Netty. If other, even more core projects (e.g. Arrow) hadn't modernized, the exceptions would be even more prolific.

    I think you have answered yourself. Make sure the libraries you rely on are well maintained, and if not - support them financially. BTW, I think that Netty is also abandoning its hacking of internals.

    > If libraries so heavily depended upon like Mockito are unable to offer a viable alternative in response to JEP 451

    But they have, and we advised them on how: https://github.com/mockito/mockito/issues/3037

    The main "ergonomic" issue was lack of help from build tools like Gradle/Maven.

  2. SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
  3. WireMock

    A tool for mocking HTTP services

    Project mention: もうPostmanに頼らない!2025年開発者が選ぶ無料APIツール15選 | dev.to | 2025-12-15

    公式サイト / GitHub:https://wiremock.org

  4. PowerMock

    PowerMock is a Java framework that allows you to unit test code normally regarded as untestable.

    Project mention: Testing the untestable | dev.to | 2025-10-23

    There's no easy way to test the start() method. In the old days, Mockito developers had pushed back against this feature, and the only alternative was PowerMock. The decision was reversed in 2020 with the 3.4.0 release, which introduced static method mocking in Mockito.

  5. microcks

    The open source, cloud native tool for API Mocking and Testing. Microcks is a Cloud Native Computing Foundation incubating project 🚀

  6. Mockneat

    MockNeat - the modern faker lib.

  7. JMockit

    Advanced Java library for integration testing, mocking, faking, and code coverage

  8. unlogged-sdk

    Unlogged SDK for recording JAVA code execution

  9. Hoverfly Java

    Java binding for Hoverfly

  10. grpcmock

    A gRPC Java testing tool to easily mock endpoints of gRPC services for IT or Unit testing

  11. juneau

    Apache Juneau

  12. mockito-object-injection

    Mockito Object Injection for JUnit5. Inject Strings and other Objects directly into Mocks without needing setters or constructor injection.

NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020).

Java Mocking discussion

Log in or Post with

Java Mocking related posts

  • Testing the untestable

    1 project | dev.to | 23 Oct 2025
  • Best API Mocking Platforms in 2024

    1 project | dev.to | 13 Nov 2024
  • 10 Best API Mocking Tools (2024 Review)

    3 projects | dev.to | 3 Nov 2024
  • Automated Testing in Node.js for Efficient API Development

    1 project | dev.to | 11 Sep 2024
  • Testes integrados com Wiremock

    2 projects | dev.to | 27 Aug 2024
  • Incredibly Useful WireMock with IntelliJ IDEA

    2 projects | dev.to | 13 Aug 2024
  • Fastify Meets WireMock: External Service Mocking

    2 projects | dev.to | 13 Feb 2024
  • A note from our sponsor - SaaSHub
    www.saashub.com | 16 Jun 2026
    SaaSHub helps you find the best software and product alternatives Learn more →

Index

What are some of the best open-source Mocking projects in Java? This list will help you:

# Project Stars
1 Mockito 15,431
2 WireMock 7,275
3 PowerMock 4,184
4 microcks 1,960
5 Mockneat 536
6 JMockit 471
7 unlogged-sdk 192
8 Hoverfly Java 175
9 grpcmock 158
10 juneau 94
11 mockito-object-injection 8

Sponsored
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com

Did you know that Java is
the 10th most popular programming language
based on number of references?