redis tests refactoring