fix mocks for set_user
Merge pull request #565 from andymckay/fix-tests

fix mocks for set_user