more code and tests