Building Tests from Specifications