This is an excerpt from Manning's book Java Testing with Spock. Login to get full access to this book.
Listing 4.13. Using expect: for preconditions