User Guide - Installation




You can download ScalaMock jars and sources from Maven Central or JCenter.

The latest released version is GitHub release.

To see all released and published versions, search at Maven Central, or Sonatype OSS Nexus.

Release versions are also in JCenter, so your favourite resolver should be covered.

CI Builds

If you want try a pre-release version, you can add Sonatype Snapshots to your resolvers. Travis publishes all commits to the Snapshot Repo. So if you need a fix urgently, you can try one of those CI builds. First, add the Snapshot Repo to your resolvers:

// e.g., for SBT:
resolvers += "Sonatype OSS Snapshots" at ""

You can search for CI builds on Sonatype OSS Nexus.


You can find the ScalaMock repository and source code on Github. The documentation is available in the gh-pages branch.

sbt projects

To use ScalaMock in sbt with ScalaTest add the following to your project file:

libraryDependencies += "org.scalamock" %% "scalamock-scalatest-support" % "(version)" % Test

To use ScalaMock with Specs2:

libraryDependencies += "org.scalamock" %% "scalamock-specs2-support" % "(version)" % Test

Maven projects

To include ScalaMock in your Maven project add the following to your pom.xml:



testCompile 'org.scalamock:scalamock-scalatest-support_2.12:(version)'