Subsitution cleanup && test enhancement