refactoring, removing unnecessary interface, changing to use non-deprecated methods in tests