FEST-Assert 1.2

A Java library that provides a fluent interface for writing assertions.
FEST-Assert is a Java library that provides a fluent interface for writing assertions. Its main goal is to improve test code readability and make maintenance of tests easier.

This project requires Java SE 5.0 or later and can be used with either JUnit or TestNG.

Currently, this module provides assertions for the following data types:

- Object
- String
- Collection
- Primitives (boolean, int, char, etc.)
- Arrays of Object
- Arrays of primitives
- BufferedImage
- Throwable
- File

Examples:

int removed = employees.removeFired();
assertThat(removed).isZero();

List newEmployees = employees.hired(TODAY);
assertThat(newEmployees).hasSize(6)
.contains(frodo, sam);

String[] newHires = employees.newHiresNames();
assertThat(newHires).containsOnly("Gandalf", "Arwen", "Gimli");

assertThat(yoda).isInstanceOf(Jedi.class)
.isEqualTo(foundJedi)
.isNotEqualTo(foundSith);

last updated on:
November 5th, 2009, 8:30 GMT
price:
FREE!
developed by:
Alex Ruiz
homepage:
fest.easytesting.org
license type:
GPL (GNU General Public License) 
category:
ROOT \ Programming \ Quality Assurance and Testing

FREE!

In a hurry? Add it to your Download Basket!

user rating 18

3.6/5
 

0/5

What's New in version 1.0
  • Lazy-loaded descriptions were added.
  • Additional root elements in the fluent interface for the assertions were removed.
read full changelog

Add your review!

SUBMIT