Updated test document generator logics.