What is JBehave?

JBehave is a framework for Behaviour-Driven Development (BDD). BDD is an evolution of test-driven development (TDD) and acceptance-test driven design, and is intended to make these practices more accessible and intuitive to newcomers and experts alike. It shifts the vocabulary from being test-based to behaviour-based, and positions itself as a design philosophy.

Features of JBehave include:

  • Pure Java implementation, which plays well with Java-based enterprises
  • Allows users to specify and run text-based scenarios, which allows "out-in" development.
  • Annotation-based binding of textual steps to Java methods
  • Auto-conversion of string arguments to any parameter type (including generic types) via custom parameter converters.
  • Scenario reporter - outputs scenarios executed in human-readable form
  • Auto-generation of pending steps so the build is not broken by a missing step, but has option to configure breaking build for pending steps.
  • Scenario can be run as JUnit tests, providing easy integration with your favourite IDE. Using alternative annotation-based unit test frameworks is equally easy.
  • Ant integration: allows scenarios to be run via Ant task
  • Maven integration: allows scenarios to be run via Maven plugin at given build phase

Want to learn more?

The Getting Started page will get you up and running in no time.