Corrections to persistent repository and tests