Improved mock factory exceptions.