fix assertions with uppercase domains + proxy_idps

and a test!
Merge pull request #3739 from seanmonstar/uppercase-gmail

fix assertions with uppercase domains + proxy_idps