ScalaTest User Guide

Writing your first test

Using assertions

Tagging your tests

Running your tests

Sharing fixtures

Sharing tests

Using matchers

Testing with mock objects

Tests as specifications

Property-based testing

Other goodies

Philosophy and design

Selecting a style

Running your tests

How can you run your tests? Let me count the ways:

  1. On the command line, use the Runner
  2. In the Scala interpreter, invoke execute or use the ScalaTest shell
  3. From Maven, use JUnitRunner and Surefire
  4. From sbt, use the ScalaTestFramework
  5. Via Ant, use the ScalaTestAntTask
  6. From IntelliJ IDEA, use JUnitRunner
  7. From the Scala IDE for Eclipse, use JUnitRunner
  8. From NetBeans, use JUnitRunner

Next, learn about sharing fixtures.

ScalaTest is brought to you by Bill Venners, with contributions from several other folks. It is sponsored by Artima, Inc.
ScalaTest is free, open-source software released under the Apache 2.0 license.

Copyright © 2009-2012 Artima, Inc. All Rights Reserved.

artima