added repository and tests