zulip/zerver/tests
Aditya Bansal 9b485f3ef4 auth: Fix bug with subdomains and GitHub auth causing apparent logouts.
This adds a new settings, SOCIAL_AUTH_SUBDOMAIN, which specifies which
domain should be used for GitHub auth and other python-social-auth
backends.

If one is running a single-realm Zulip server like chat.zulip.org, one
doesn't need to use this setting, but for multi-realm servers using
social auth, this fixes an annoying bug where the session cookie that
python-social-auth sets early in the auth process on the root domain
ends up masking the session cookie that would have been used to
determine a user is logged in.  The end result was that logging in
with GitHub on one domain on a multi-realm server like zulipchat.com
would appear to log you out from all the others!

We fix this by moving python-social-auth to a separate subdomain.

Fixes: #9847.
2018-07-10 16:49:00 +05:30
..
fixtures billing: Update billing system. 2018-07-09 14:33:07 +05:30
images upload: Add test jpg image with no exif data. 2018-05-31 08:08:59 -07:00
__init__.py
test_alert_words.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_archive.py narrow: Add is_web_public_compatible check for narrows. 2018-05-21 08:45:48 -07:00
test_attachments.py lint: Prevent `self: Any` annotations. 2017-12-08 19:00:18 -08:00
test_audit_log.py models: Add SUBSCRIPTION_DEACTIVATED event type constant to RealmAuditLog. 2018-07-10 15:42:26 +05:30
test_auth_backends.py auth: Fix bug with subdomains and GitHub auth causing apparent logouts. 2018-07-10 16:49:00 +05:30
test_bots.py test flake: Prevent flaky test with less common id. 2018-06-26 16:56:24 -04:00
test_bugdown.py bugdown: Move global variables to arguments.py. 2018-07-09 15:45:45 +05:30
test_cache.py tests: Add 100% test coverage to zerver/apps.py. 2018-05-14 10:36:10 -07:00
test_compatibility.py zerver/tests: Use python 3 syntax for typing in most files. 2017-11-16 21:52:01 -08:00
test_custom_profile_data.py custom fields: Allow list of users in user type of custom fields. 2018-06-16 09:37:49 -07:00
test_decorators.py 2FA: Add zulip_otp_required decorator. 2018-05-23 15:46:57 -07:00
test_digest.py digest: Make newly registered users data inaccessible to guest users. 2018-06-03 09:30:59 -07:00
test_docs.py portico: Update text of why-zulip. 2018-06-03 09:37:00 -07:00
test_email_change.py registration: Use tokenized noreply address in email change. 2018-06-23 12:03:30 -07:00
test_email_log.py zerver/tests: Use python 3 syntax for typing. 2017-11-18 15:35:57 -08:00
test_email_mirror.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_embedded_bot_system.py mypy: test_embedded_bot_system.py: add asserts & remove from mypy.ini. 2018-06-19 10:48:38 -07:00
test_event_queue.py minor: Clean up how we set flags in events. 2018-03-28 15:56:03 -07:00
test_events.py zerver/lib/events.py: Fix custom field values not updated in apply_events. 2018-07-10 10:30:23 +05:30
test_external.py zerver/tests: Change use of typing.Text to str. 2018-05-12 15:22:39 -07:00
test_feedback.py Add basic test for FeedbackBot. 2018-03-04 13:31:33 -08:00
test_home.py webpack: Transition app.js to be compiled by webpack. 2018-07-05 11:03:08 +02:00
test_hotspots.py hotspots: Add ALWAYS_SEND_ALL_HOTSPOTS in dev_settings. 2018-03-19 10:39:43 -07:00
test_i18n.py test_i18n: Stop using six.moves for SimpleCookie. 2018-05-09 20:45:45 -07:00
test_import_export.py import: import RealmAuditLog. 2018-07-10 15:53:15 +05:30
test_json_encoder_for_html.py zerver: Remove simplejson dependency. 2017-11-21 21:51:48 -08:00
test_link_embed.py mypy: test_link_embed.py: add assert & remove from mypy.ini. 2018-06-19 10:48:38 -07:00
test_logging_handlers.py mypy: Set local_partial_types = True. 2018-05-21 22:41:00 -07:00
test_management_commands.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_message_edit_notifications.py zerver/tests: Change use of typing.Text to str. 2018-05-12 15:22:39 -07:00
test_messages.py models: Add USER_SOFT_ACTIVATED event type constant to RealmAuditLog. 2018-07-10 15:42:26 +05:30
test_middleware.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_migrations.py migration_tests: Document the migration test framework. 2018-05-21 09:59:55 -07:00
test_muting.py tests: Replace api_auth usages with auth methods in zerver/tests. 2017-12-18 09:24:09 -05:00
test_narrow.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_new_users.py auth: Added time conversion in new login emails. 2018-06-07 08:40:22 -07:00
test_notifications.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_onboarding.py create_realm_internal_bots: Refactor to extract main op as a function. 2018-05-23 11:53:22 +05:30
test_openapi.py api docs: Allow validation against schemas for any response. 2018-07-03 20:11:05 +02:00
test_outgoing_webhook_interfaces.py outgoing webhooks: Send additional useful data. 2018-05-25 10:33:40 -07:00
test_outgoing_webhook_system.py zerver/tests: Change use of typing.Text to str. 2018-05-12 15:22:39 -07:00
test_presence.py test_presence: Fix nondeterministic test failures. 2018-05-20 22:02:43 -07:00
test_push_notifications.py push notifications: Clean up unregistered/bad APNS tokens. 2018-05-21 11:30:56 -07:00
test_queue.py requirements: Upgrade pyflakes to 2.0.0. 2018-05-24 11:31:36 -07:00
test_queue_worker.py Add tests for SignupWorker error handling. 2018-02-28 12:31:38 -08:00
test_reactions.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_realm.py zerver/tests: Change use of typing.Text to str. 2018-05-12 15:22:39 -07:00
test_realm_domains.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_realm_emoji.py emoji: Make uploading new realm emoji inaccessible for guest users. 2018-06-16 06:33:14 -07:00
test_realm_filters.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_report.py tests: Refactor use of test and webhook data fixtures. 2018-04-19 21:50:29 -07:00
test_retention.py Eliminate get_user_profile_by_email from test_classes. 2017-11-26 15:47:56 -08:00
test_service_bot_system.py bots: Fix behavior for bots mentioned in PMs. 2018-06-03 22:29:15 -07:00
test_sessions.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_settings.py user_settings: Prevent LDAP users from setting a Zulip password. 2018-05-28 22:47:47 -07:00
test_signup.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_slack_importer.py import: import RealmAuditLog when 'zerver_realmauditlog` is missing. 2018-07-10 16:00:19 +05:30
test_slack_message_conversion.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_soft_deactivation.py populate_db: Add new user of "guest" type. 2018-04-20 16:20:00 -07:00
test_subdomains.py zerver/tests: Use python 3 syntax for typing (part 4). 2017-11-21 22:01:19 -08:00
test_submessage.py submessages: Add submessage_id to submessage event. 2018-05-30 14:47:36 -07:00
test_subs.py Replace remaining user-facing occurences of the term "invite-only". 2018-06-27 12:34:29 -07:00
test_templates.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_timestamp.py zerver/tests: Use python 3 syntax for typing. 2017-11-08 12:50:27 -08:00
test_tornado.py zerver/tests: Change use of typing.Text to str. 2018-05-12 15:22:39 -07:00
test_tutorial.py zerver/tests: Use python 3 syntax for typing. 2017-11-08 12:50:27 -08:00
test_type_debug.py mypy: Remove some now-unnecessary type: ignores. 2018-03-28 10:39:05 -07:00
test_typing.py tests: Replace api_auth usages with auth methods in zerver/tests. 2017-12-18 09:24:09 -05:00
test_unread.py zerver/tests: Change use of typing.Text to str. 2018-05-10 14:19:49 -07:00
test_upload.py Enable pycodestyle W605 (invalid escape sequence). 2018-07-03 16:54:46 +02:00
test_urls.py django-2.0: Shift to resolvers from urlresolvers. 2018-01-30 10:53:54 -08:00
test_user_groups.py guest: Restrict guest access to user group creation and updation. 2018-06-19 11:04:14 -07:00
test_users.py signup: Prevent users from signing up with email containing +. 2018-06-23 12:03:30 -07:00
test_webhooks_common.py test_webhooks_common: Add logging for a test flake case. 2018-05-17 09:18:31 -07:00
test_widgets.py Support zform-based widget content in the server. 2018-05-24 09:30:22 -07:00
test_zcommand.py zcommand: Raise error when command doesn't begin with a slash. 2018-07-01 20:32:36 -04:00
test_zephyr.py zerver/tests: Use python 3 syntax for typing (part 3). 2017-11-21 22:01:19 -08:00
tests.py retention-period: Add retention period to front-end admin organization settings. 2017-03-25 17:57:18 -07:00