Document test factory refactored.