Some test refactoring, some oauth tests