p

powermock

PowerMock allows you to unit test code normally regarded as untestable. For instance it is possible to mock static methods, remove static initializers, allow mocking without dependency injection and more. PowerMock works by bytecode manipulation. PowerMock also contain some utilities that gives you easier access to an objects internal state. PowerMock can be used to test otherwise untestable code and also to achieve a cleaner separation between test and production code.
http://www.powermock.org
The Apache Software License, Version 2.0
Johan Haleby Jan Kronquist
文件下载
文件名 操作
powermock-1.4.7.pom 下载
Apache Maven
<dependency>
  <groupId>org.powermock</groupId>
  <artifactId>powermock</artifactId>
  <version>1.4.7</version>
  <type>pom</type>
</dependency>
Gradle Groovy
implementation 'org.powermock:powermock:1.4.7'
Gradle Kotlin
implementation("org.powermock:powermock:1.4.7")
Scala SBT
libraryDependencies += "org.powermock" % "powermock" % "1.4.7"
Groovy Grape
@Grapes(
  @Grab(group='org.powermock', module='powermock', version='1.4.7')
)
Apache Ivy
<dependency org="org.powermock" name="powermock" rev="1.4.7" />
Leiningen
[org.powermock/powermock "1.4.7"]
Apache Buildr
'org.powermock:powermock:jar:1.4.7'