improvements to the SSO fields (PR #9459)

  • add location as a SSO field, with corresponding sso_overrides_location setting to allow override of local value
  • add sso_overrides_website setting that allows to prevent local changes

GitHub

Looks like some tests are failing here. Can you fix those please?

Fixed one, but not sure what’s the best way to address the other. Seems the test doesn’t find the location field that is now dependent on the sso_override_location setting (defaults to false). Quite possible that I’m doing something wrong as I’m new to Discourse/Ruby. Could use some help?

It looks to me like you have to add the can_edit_location that you added to the user serializer to the qunit test fixtures to pass. My advice would be to run the qunit tests locally, and find the failure. Then you can re-run that one and figure out why the field is not showing up.

Thanks for the tip — seems it passes now. Please double-check the code as this is a new stack for me.

Looks generally fine to me, but given it is a protocol level change can we add bit more testing to cover both on and off cases servers side?

Something like this? Just following along what is done for the sso_overrides_bio.

This is looking good to me, the change looks safe!

Thanks @mentalstring