discourse/app
Andreas Haller 661f2057f7 Improve the omniauth controller specs. Fix the email provided by CAS. Get name from CAS attributes.
* Make omniauth controller specs more robust by using shared examples for all authentication providers in controller spec. – Still passing. Yay!

* Return "casuser", instead of "casuser@" when no cas_domainname is configured.

* If no cas_domainname is configured, the CAS authentication would return "casuser@" for the users email field, because it tried to assume the email adress of the CAS user by it's username + cas_domainname.
  Now it just returns the username instead of adding an "@" if cas_domainname is not configured.
  This especially makes sense on CAS setups where the username equals the users email adress.
  The old behaviour, if cas_domainname is configured, was not changed.

* Fetch the email from CAS attributes if provided
  If the cas:authenticationSuccess (handled via omniauth-cas) response gives us an email use that.
  If not, behave as before (username or username@cas_domainname).

* Fetch the (full) name from CAS attributes if provided
  If the CAS response by omniauth provides a [:info][:name] field, prefer this over the uid, because we want the name to be a "Full Name", instead of just a "shortname"
2013-07-04 12:01:39 +02:00
..
assets use a color constant instead of hardcoding 2013-07-04 01:11:45 -07:00
controllers Improve the omniauth controller specs. Fix the email provided by CAS. Get name from CAS attributes. 2013-07-04 12:01:39 +02:00
helpers Don't double render faq and privacy policy 2013-07-03 11:57:27 -04:00
mailers Private messages have instructions for reply by email. We also strip X-Discourse headers 2013-06-25 11:35:26 -04:00
models Merge pull request #1139 from stephankaag/correct_image_url_rails4 2013-07-03 23:29:43 -07:00
serializers Refactor: Move Topic Details into better objects, identity map, tests, query string filters 2013-07-02 10:36:46 -04:00
services Fix update statement for Rails 4 preparation 2013-07-03 11:17:16 -04:00
views FIX: Invalid Unicode in preload store JSON 2013-07-02 20:43:52 -04:00