powermock-easymock-single-jar-release-full

Single jar containing binaries for PowerMock core, EasyMock and all test framework modules.

License

License

Categories

Categories

PowerMock Unit Testing
GroupId

GroupId

org.powermock
ArtifactId

ArtifactId

powermock-easymock-release-full
Last Version

Last Version

1.6.4
Release Date

Release Date

Type

Type

jar
Description

Description

powermock-easymock-single-jar-release-full
Single jar containing binaries for PowerMock core, EasyMock and all test framework modules.

Download powermock-easymock-release-full

How to add to project

<!-- https://jarcasting.com/artifacts/org.powermock/powermock-easymock-release-full/ -->
<dependency>
    <groupId>org.powermock</groupId>
    <artifactId>powermock-easymock-release-full</artifactId>
    <version>1.6.4</version>
</dependency>
// https://jarcasting.com/artifacts/org.powermock/powermock-easymock-release-full/
implementation 'org.powermock:powermock-easymock-release-full:1.6.4'
// https://jarcasting.com/artifacts/org.powermock/powermock-easymock-release-full/
implementation ("org.powermock:powermock-easymock-release-full:1.6.4")
'org.powermock:powermock-easymock-release-full:jar:1.6.4'
<dependency org="org.powermock" name="powermock-easymock-release-full" rev="1.6.4">
  <artifact name="powermock-easymock-release-full" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.powermock', module='powermock-easymock-release-full', version='1.6.4')
)
libraryDependencies += "org.powermock" % "powermock-easymock-release-full" % "1.6.4"
[org.powermock/powermock-easymock-release-full "1.6.4"]

Dependencies

compile (21)

Group / Artifact Type Version
org.powermock : powermock-core jar 1.6.4
org.powermock : powermock-api-easymock jar 1.6.4
org.powermock : powermock-module-junit4-common jar 1.6.4
org.powermock : powermock-module-junit4 jar 1.6.4
org.powermock : powermock-module-junit4-legacy jar 1.6.4
org.powermock : powermock-module-junit3 jar 1.6.4
org.powermock : powermock-reflect jar 1.6.4
org.powermock : powermock-api-support jar 1.6.4
org.powermock : powermock-module-testng jar 1.6.4
org.powermock : powermock-module-testng-common jar 1.6.4
org.powermock : powermock-classloading-base jar 1.6.4
org.powermock : powermock-core jar 1.6.4
org.powermock : powermock-api-easymock jar 1.6.4
org.powermock : powermock-module-junit4-common jar 1.6.4
org.powermock : powermock-module-junit4 jar 1.6.4
org.powermock : powermock-module-junit4-legacy jar 1.6.4
org.powermock : powermock-module-junit3 jar 1.6.4
org.powermock : powermock-module-testng jar 1.6.4
org.powermock : powermock-reflect jar 1.6.4
org.powermock : powermock-api-support jar 1.6.4
org.powermock : powermock-classloading-base jar 1.6.4

Project Modules

There are no modules declared in this project.

PowerMock

Build Status Maven Central Download Javadoc

Writing unit tests can be hard and sometimes good design has to be sacrificed for the sole purpose of testability. Often testability corresponds to good design, but this is not always the case. For example final classes and methods cannot be used, private methods sometimes need to be protected or unnecessarily moved to a collaborator, static methods should be avoided completely and so on simply because of the limitations of existing frameworks.

PowerMock is a framework that extends other mock libraries such as EasyMock with more powerful capabilities. PowerMock uses a custom classloader and bytecode manipulation to enable mocking of static methods, constructors, final classes and methods, private methods, removal of static initializers and more. By using a custom classloader no changes need to be done to the IDE or continuous integration servers which simplifies adoption. Developers familiar with the supported mock frameworks will find PowerMock easy to use, since the entire expectation API is the same, both for static methods and constructors. PowerMock aims to extend the existing API's with a small number of methods and annotations to enable the extra features. Currently PowerMock supports EasyMock and Mockito.

When writing unit tests it is often useful to bypass encapsulation and therefore PowerMock includes several features that simplifies reflection specifically useful for testing. This allows easy access to internal state, but also simplifies partial and private mocking.

Please note that PowerMock is mainly intended for people with expert knowledge in unit testing. Putting it in the hands of junior developers may cause more harm than good.

News

  • 2019-04-21: PowerMock 2.0.2 has been released and is avaliable in Maven Central. The release includes fixes for issue with PowerMock JavaAgent and the latest JDK and a security issue with the build script.
  • 2019-01-07: PowerMock 2.0.0 has been released. Main changes: offical supporting Mockito 2.x and dropping supporting Mockito 1.x. This release also supports Java 9. Other change read in release notes.
  • 2017-08-12: PowerMock 1.7.1 has been released with one, but significant change: the old API for verifying static mock has been deprecated and a new one has been added. Old API will be removed in version PowerMock 2.0 due to incompatibility with Mockito Public API.
  • 2017-06-16: PowerMock 1.7.0 has been released with support for Mockito 2 (not only beta versions) and new features such as global @PowerMockIgnore as well as bug fixes and other improvements. See release notes and change log for details.
  • 2017-02-03: Johan blogs about how to mock slf4j with PowerMock at his blog

Older News

Documentation

Contributing to PowerMock

Please, read the guideline for a new contributor before start.

Support and discussion

Join the mailing-list here for questions, feedback and support.

org.powermock

Jayway

Versions

Version
1.6.4
1.6.3
1.6.2
1.6.1
1.6.0
1.5.6
1.5.5
1.5.4
1.5.3
1.5.2
1.5.1
1.5
1.4.12
1.4.11
1.4.10
1.4.9
1.4.8
1.4.7