Improved testing APIs.