User Guide - Installation

Installation

Packages

Releases

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

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 JFrog JCenter and Bintray, 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 "https://oss.sonatype.org/content/repositories/snapshots"

You can search for CI builds on Sonatype OSS Nexus.

Sources

You can find the ScalaMock repository and source code on Github.

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:

<dependency>
    <groupId>org.scalamock</groupId>
    <artifactId>scalamock-scalatest-support_2.11</artifactId>
    <version>(version)</version>
    <scope>test</scope>
</dependency>

Gradle

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