docbrown/spec/factories
Molly Struve e87dead7ad
Use new UserSetting and UserNotificationSettings and Ignore Related User Table Fields (#14121)
* schema file undelete description

* feat: v1 of the script

* Flesh out remaining enums under their categories

* complete UsersSettings data update script

* complete DUS for relevant attributes in users and profiles tables

* complete DUS for users_notification_settings

* alphabetize user_settings sql file

* safeguard against null values for "null: false" settings

* Set up actual UsersSettings DUS and specs files

* fix broken DUS script

* complete specs for UsersSetting DUS

* Address QA of specs

* complete specs for users_notification_settings DUS

* fix the typos (thanks Julianna!)

* begin implementation

* still building

* add missing attribute "email_membership_newsletter"

* complete sync code (except race condition for user profile)

* complete implementation, remains tests

* Address PR review and fix Travis fails

* remove superfluous Profile.new

* fix travis fails

* feat: update the users_notification_setting attributes from the user model

* feat: use the config fonts enums to display the fonts

* feat: loop through the keys

* fix profile = nil blowing up; add specs for notification_setting model

* remove unneeded spec

* remove feed validation until after sync code removed; fixes feed_import spec failures

* remove spec associated with feed_url validation in user_setting model

* fix failing spec 😅

* add TODO

* feat: set the user settings in the user controller  and use it in the customization form

* feat: move some update logic to the users settings controller thats being used from customization

* feat: show the updated values form the users_settingd and not the user instance

* Generalize redirect back to current tab

* still trying to reflect changed theme upon refresh

* customizations take effect on refresh

* remove 'with_feed' scope from user model

Co-authored-by: Jamie Gaskins <jamie@forem.com>

* start with takeover for fields previously in profiles table

* Takeover code for `publishing_from_rss` section in Settings (#13914)

* implement takeover code part 1

* implement takeover code

* fix feed fetch

* need rhymes help

* complete implementation; specs pending

* fix STUPID omission that caused so many headaches 😫

* implement profile fields pointing to users_settings 🎉

* run migrations

* implement inbox type & guidelines takeover code; specs pending (#13911)

* Point changes in notification settings to `users_notification_settings` table (#13910)

* implement takeover code; remains specs

* address PR feedback; remove related sync code

* address PR review feedback

* need help with routing and specs

* address pr review

* addressing pr review

* Treat implementation edge cases and omissions 😅

* fix uncommented comment

* fixing implementation cases

* address more PR review feedback

* fixing notifications use-cases

* refactor settings controller

* more pr review changes

* solving bugs

* fix broken onboarding

* handle eperience_level calls

* more fixes

* remove unneeded mappings

* add To-dos for quety updates

* remove done TODO

* purge done TODOs

* update notification_settings-related queries

* start fixing specs

* fixing specs

* fix notification and lrg_forem specs

* fixing broken specs

* still fixing

* fix line dif and remove reloads from user.rb

* run specs

* silence bullet and other fixes

* remove setting migration scripts and specs, fix more settings for specs

* handle missing user for article builder and fix notification specs

* fix some final controller specs and re-add incorrectly removed specs

* remove deprecated data update scripts and related workers, put travis back

* refactor admin tags mods controller, write/move specs for users notifications settings controller

* schema cleanup and other small refactors for consistency

* set field we can invalidate in spec via active record instead of at the db level

* remove I think an uneccessary hook call from subscribe_to_mailchimp_newsletter

* use bnefore_create to setup settings, please dont blow up the test suite

* mailchimp bot fix

* remove decorator in favor of single model method

Co-authored-by: Arit Amana <msarit@gmail.com>
Co-authored-by: Ridhwana <ridhwana.khan16@gmail.com>
Co-authored-by: Arit Amana <32520970+msarit@users.noreply.github.com>
Co-authored-by: Jamie Gaskins <jamie@forem.com>
2021-07-08 09:31:34 -05:00
..
activesupport_events.rb Routine rubocop fixes (#4924) 2019-11-25 14:13:22 -05:00
ahoy.rb Add metrics around welcome notifications + their click events (#9239) 2020-07-10 12:30:45 +02:00
api_secrets.rb Listings creation and update API (#4014) 2019-09-24 07:03:52 -07:00
articles.rb Create DiscussionLocks (#13905) 2021-06-10 11:04:33 -04:00
audit_logs.rb [deploy] Moderator and admin actions log (#6797) 2020-03-26 16:59:24 -05:00
badge_achievements.rb Bump factorybot rails (#475) 2018-08-24 17:28:26 -04:00
badges.rb Ensure model properties in factories are unique (#5190) 2019-12-20 12:21:16 -06:00
banished_users.rb Introduce BanishedUser table (#5589) [deploy] 2020-01-21 17:15:58 -05:00
broadcasts.rb Bump rubocop from 1.17.0 to 1.18.0 (#14107) 2021-07-01 13:51:49 +02:00
chat_channel_memberships.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
chat_channels.rb 🚀 Ability to allow tag moderators to create chat channels (#9741) 2020-12-08 13:10:36 +07:00
collections.rb Show correct number in series truncation. (#13799) 2021-05-24 15:47:06 -06:00
comments.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
consumer_apps.rb Have specs run without Redis and refactor ConsumerApp and Device (#13647) 2021-05-07 08:03:16 +02:00
credits.rb Allow users to belong to multiple orgs (#2583) 2019-06-04 09:30:52 -04:00
custom_profile_fields.rb Add custom profile fields (#10202) 2020-09-09 14:37:15 +00:00
data_update_script.rb Feature:Send Alerts for Failed DataUpdateScripts to Datadog (#11381) 2020-11-12 10:59:54 -06:00
devices.rb Have specs run without Redis and refactor ConsumerApp and Device (#13647) 2021-05-07 08:03:16 +02:00
discussion_locks.rb Create DiscussionLocks (#13905) 2021-06-10 11:04:33 -04:00
display_ad_events.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
display_ads.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
doorkeeper_access_grants.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
doorkeeper_access_tokens.rb Update core API endpoints to support access_token (#3644) 2019-08-08 15:55:23 -03:00
doorkeeper_applications.rb Update core API endpoints to support access_token (#3644) 2019-08-08 15:55:23 -03:00
email_authorizations.rb [deploy] Add EmailAuthorization model (#6335) 2020-03-02 12:14:24 -05:00
email_messages.rb [deploy] Add missing foreign keys to ahoy_messages and articles (#10321) 2020-09-16 19:47:03 +02:00
events.rb Update Faker to 2.1.0 (#3652) 2019-08-07 15:59:23 -04:00
feedback_messages.rb [deploy] Enforce Uniq Abuse Reports from Reporters (#7831) 2020-05-14 09:03:10 -04:00
field_test_memberships.rb Remove concept of "ongoing" field tests and clarify a/b test instructions/expectations. (#11734) 2020-12-07 13:52:54 -05:00
follow.rb Fix delayed job errors related to follows #1621 (#1835) 2019-02-23 18:16:20 -08:00
gdpr_delete_requests.rb Confirmations that users GDPR data was deleted (#11039) 2020-12-14 12:49:45 +03:00
github_repos.rb Ensure model properties in factories are unique (#5190) 2019-12-20 12:21:16 -06:00
html_variant_successes.rb [deploy] Refactor:Move Remove Old HTML Variant Data task to Sidekiq (#9925) 2020-08-22 18:36:22 -05:00
html_variant_trials.rb [deploy] Refactor:Move Remove Old HTML Variant Data task to Sidekiq (#9925) 2020-08-22 18:36:22 -05:00
html_variants.rb [deploy] Remove sidebar variant from CTA (#8040) 2020-05-23 13:35:43 -04:00
identities.rb Add functionality to remove and recover identity (#3377) 2019-07-03 12:01:16 -04:00
listing_categories.rb [deploy] Rename classified listings (#7910) 2020-05-27 13:35:09 +00:00
listings.rb [deploy] Rename classified listings (#7910) 2020-05-27 13:35:09 +00:00
mentions.rb Fix mention validation when validating an empty instance (#3188) 2019-06-18 21:36:01 -04:00
messages.rb Remove unused factories and traits (#11051) 2020-10-26 12:28:25 +01:00
navigation_links.rb Update NavigationLink handling (#12316) 2021-01-20 13:57:59 -05:00
note.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
notification_subscriptions.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
notifications.rb Create rake Task to Destroy Old Notifications (#5180) [deploy] 2019-12-26 13:17:34 -06:00
organization_memberships.rb [deploy] Rubocop: fix violations of Layout/LineLength (#9197) 2020-07-08 08:36:36 -05:00
organizations.rb Fix rubocop Rails.root.path complaints (#5114) 2019-12-16 12:13:15 -05:00
page_views.rb Pro: add referrers to dashboard and single article stats (#3295) 2019-06-25 13:58:09 -04:00
pages.rb Improve test speed (#3957) [ci skip] 2019-09-12 16:17:20 -04:00
podcast_episode_appearances.rb Add podcast_appearances joined table (forem#82) (#11354) 2020-11-30 17:12:52 +01:00
podcast_episode_rss_items.rb Update Faker to 2.1.0 (#3652) 2019-08-07 15:59:23 -04:00
podcast_episodes.rb Sequence factory podcast episode slugs and guids to ensure uniqueness (#5184) 2019-12-19 19:13:19 -05:00
podcast_ownership.rb Podcast ownership join table (MLH Fellowship #81) (#11410) 2020-11-19 12:41:17 +01:00
podcasts.rb Fix rubocop Rails.root.path complaints (#5114) 2019-12-16 12:13:15 -05:00
poll_options.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
poll_skips.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
poll_votes.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
polls.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
profile_field_groups.rb [deploy] Introduce ProfileFieldGroup model (#10007) 2020-08-28 10:51:33 +07:00
profile_fields.rb Settings: Correctly display profile field static values (#13887) 2021-06-01 16:16:15 +02:00
profile_pins.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
profiles.rb Migrate "static" profile fields into new columns (#13641) 2021-05-26 14:40:18 -05:00
rating_votes.rb [deploy] Add missing foreign keys to models related to users (#10018) 2020-08-31 15:39:57 +02:00
reactions.rb Handle negative reactions on comments (#7805) 2020-05-13 09:27:38 -04:00
response_templates.rb Add response templates model and table (#6615) 2020-03-16 09:52:03 +07:00
sponsorships.rb Sponsorship: add model (step 1) (#3438) 2019-07-10 15:58:37 -04:00
suspended_usernames.rb Prevent suspended users from self-deleting and returning (#12503) 2021-02-11 09:28:59 +07:00
tag_adjustments.rb Mod tooling: add tags via /mod refactor (#5017) 2019-12-13 13:02:45 -05:00
tags.rb Remove Elasticsearch ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ (#13606) 2021-05-03 11:09:45 -04:00
tweets.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
user_blocks.rb [deploy] Finalize deleting user associations (#5624) 2020-01-23 11:29:47 -05:00
user_subscription.rb [deploy] Rubocop: fix violations of Layout/LineLength (#9197) 2020-07-08 08:36:36 -05:00
users.rb Use new UserSetting and UserNotificationSettings and Ignore Related User Table Fields (#14121) 2021-07-08 09:31:34 -05:00
users_notification_settings.rb Use new UserSetting and UserNotificationSettings and Ignore Related User Table Fields (#14121) 2021-07-08 09:31:34 -05:00
users_settings.rb Use new UserSetting and UserNotificationSettings and Ignore Related User Table Fields (#14121) 2021-07-08 09:31:34 -05:00
webhook_endpoints.rb Routine rubocop fixes (#4924) 2019-11-25 14:13:22 -05:00