discourse/spec/requests
Blake Erickson fec68d3d25 DEV: Confirm email when creating users via the API
This commit is for a frequently requested task on meta so that only 1
API call is needed instead of 3!

In order to create a user via the api and not have them receive an
activation email you can pass in the `active=true` flag. This prevents
sending an email, but it is only half of the solution and puts the db in
a weird state where it has an active user with an unconfirmed email.

This commit fixes that and ensures that if the `active=true` flag is set
the user's email is also marked as confirmed.

This change only applies to admins using the API.

Related topics on meta:

 - https://meta.discourse.org/t/-/68663
 - https://meta.discourse.org/t/-/33133
 - https://meta.discourse.org/t/-/36133
2020-04-14 14:56:32 -06:00
..
admin DEPRECATION: Remove support for api creds in query params (#9106) 2020-04-06 16:55:44 -06:00
about_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
application_controller_spec.rb FIX: correctly remove authentication_data cookie on oauth login flow 2020-03-21 14:34:25 -07:00
associate_accounts_controller_spec.rb DEV: Add test to ensure :after_auth event is triggered (#8400) 2019-11-25 14:31:57 +02:00
badges_controller_spec.rb DEV: Make badge test resilient to disabled badges 2020-02-11 18:01:33 +00:00
bookmarks_controller_spec.rb FEATURE: Send notifications for time-based and At Desktop bookmark reminders (#9071) 2020-03-12 10:16:00 +10:00
categories_controller_spec.rb FIX: prevent scheduled publishing to deleted category 2020-03-24 16:59:42 +11:00
category_hashtags_controller_spec.rb DEV: avoid double sign-in which can lead to flaky tests 2019-06-03 10:15:49 +10:00
clicks_controller_spec.rb DEV: Fix failling test. 2019-05-07 11:19:13 +03:00
composer_messages_controller_spec.rb DEV: Prefabrication (test optimization) (#7414) 2019-05-07 13:12:20 +10:00
csp_reports_controller_spec.rb DEV: Only include "report-sample" CSP directive when reporting is enabled (#9337) 2020-04-02 11:16:38 -04:00
directory_items_controller_spec.rb FIX: move total rows count & load more URL inside meta. 2020-04-03 07:32:50 +05:30
draft_controller_spec.rb FIX: Confirm `draft_key` is present on GET 2020-02-14 11:06:12 -05:00
drafts_controller_spec.rb SECURITY: Respect topic permissions when loading draft metadata 2020-03-23 11:30:40 +00:00
email_controller_spec.rb DEV: Implement a faster Discourse.cache 2019-11-27 16:11:49 +11:00
embed_controller_spec.rb DEPRECATION: Remove support for api creds in query params (#9106) 2020-04-06 16:55:44 -06:00
exceptions_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
export_csv_controller_spec.rb fix the build (take 2). 2019-12-24 19:27:35 +05:30
extra_locales_controller_spec.rb FIX: Better error handling for invalid locale bundle versions 2019-11-11 22:30:32 +01:00
finish_installation_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
forums_controller_spec.rb Add tests for /srv/status behavior 2020-03-09 14:06:13 -07:00
groups_controller_spec.rb DEV: Move requested_group_id custom field from post to topic (#9127) 2020-03-24 11:12:52 +02:00
inline_onebox_controller_spec.rb DEV: Prefabrication (test optimization) (#7414) 2019-05-07 13:12:20 +10:00
invites_controller_spec.rb FEATURE: Add timezone to core user_options (#8380) 2019-11-25 10:49:27 +10:00
list_controller_spec.rb FIX: Make category slug validation less strict (#8915) 2020-02-11 17:01:12 +02:00
metadata_controller_spec.rb FEATURE: Enable offline browsing and fullscreen PWA in iOS by default 2020-04-07 16:58:21 -03:00
notifications_controller_spec.rb DEV: Prefer `public_send` over `send`. 2019-05-07 09:33:21 +08:00
offline_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
omniauth_callbacks_controller_spec.rb FIX: correctly remove authentication_data cookie on oauth login flow 2020-03-21 14:34:25 -07:00
onebox_controller_spec.rb FIX: Cache failed onebox URL request server-side (#8421) 2019-11-28 07:48:29 +10:00
permalinks_controller_spec.rb DEV: improve usability of subfolder specs 2019-11-15 16:48:24 +11:00
post_action_users_controller_spec.rb More prefabrication 2019-05-10 08:34:04 -04:00
post_actions_controller_spec.rb DEV: Prefabrication (test optimization) (#7414) 2019-05-07 13:12:20 +10:00
post_readers_controller_spec.rb FIX: Filter readers avatars correctly when the post is a whisper 2019-12-03 10:50:02 -03:00
posts_controller_spec.rb DEPRECATION: Remove support for api creds in query params (#9106) 2020-04-06 16:55:44 -06:00
published_pages_controller_spec.rb FEATURE: Support for publishing topics as pages (#9364) 2020-04-08 12:52:36 -04:00
push_notification_controller_spec.rb DEV: Prefabrication (test optimization) (#7414) 2019-05-07 13:12:20 +10:00
reviewable_claimed_topics_controller_spec.rb FIX: Make reviewable claiming work with deleted topics (#9040) 2020-02-25 15:49:23 +02:00
reviewables_controller_spec.rb FEATURE: add after-reviewable-post-user plugin outlet (#9397) 2020-04-09 11:32:39 -07:00
robots_txt_controller_spec.rb DEV: improve usability of subfolder specs 2019-11-15 16:48:24 +11:00
safe_mode_controller_spec.rb FEATURE: Always disable customizations on the `/safe-mode` route (#9052) 2020-02-28 10:53:11 +00:00
search_controller_spec.rb DEV: s/\$redis/Discourse\.redis (#8431) 2019-12-03 10:05:53 +01:00
session_controller_spec.rb FIX: Missing timezone guess on email session login (#9404) 2020-04-10 13:19:39 -05:00
similar_topics_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
site_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
static_controller_spec.rb DEV: Upgrade Discourse to Rails 6 (#8083) 2019-09-12 10:41:50 +10:00
steps_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
stylesheets_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
svg_sprite_controller_spec.rb UX: introduces icon-picker component for badges (#8844) 2020-02-05 00:41:10 +01:00
tag_groups_controller_spec.rb DEV: Prefabrication (test optimization) (#7414) 2019-05-07 13:12:20 +10:00
tags_controller_spec.rb FIX: tag info misleading message saying it's not restricted 2020-02-05 15:23:39 -05:00
theme_javascripts_controller_spec.rb DEV: Prefabrication (test optimization) (#7414) 2019-05-07 13:12:20 +10:00
topics_controller_spec.rb FIX: error when changing a topic's category and creating a tag 2020-03-30 16:43:01 -04:00
uploads_controller_multisite_spec.rb FIX: Change secure media to encompass attachments as well (#9271) 2020-03-26 07:16:02 +10:00
uploads_controller_spec.rb DEPRECATION: Remove support for api creds in query params (#9106) 2020-04-06 16:55:44 -06:00
user_actions_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
user_api_keys_controller_spec.rb FEATURE: Hash user API keys in the database (#9344) 2020-04-07 16:42:52 +03:00
user_avatars_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00
user_badges_controller_spec.rb DEPRECATION: Remove support for api creds in query params (#9106) 2020-04-06 16:55:44 -06:00
users_controller_spec.rb DEV: Confirm email when creating users via the API 2020-04-14 14:56:32 -06:00
users_email_controller_spec.rb FIX: When admin changes another user's email auto-confirm the change (#9001) 2020-02-20 09:52:21 +10:00
webhooks_controller_spec.rb DEV: Apply rubocop (#8926) 2020-02-11 16:21:03 +00:00
wizard_controller_spec.rb DEV: use #frozen_string_literal: true on all spec 2019-04-30 10:27:42 +10:00