* Refactor user_show_spec to check for exact JSON-LD data to improve testing
* Extracts data out into factory objects to shorten # of lines in test
* Extracts JSON-LD into a parsed object for more precise testing
* Shortens test to be within the 15 line rubocop limit
* Resolves rubocop multi-line errors
* Refactor user.update_columns to be a single method
* Add :with_all_info trait to users factory
* Adds trait that holds all necessary info for user JSON-LD
* Removes user.update_columns method from the user_show_spec
* Adds the :with_all_info trait to the user in the spec
* Wrap test in rubocop:disable to resolve ExampleLength errors
* Removes let blocks that once held extracted code
* Adds code back to the data structure as inline code
* Resolves even more rubocop errors... hopefully
* Allow admins to suggest default users to follow during onboarding
Allows the onboarding "follow users" slide to be configured by admins.
Closes https://github.com/thepracticaldev/dev.to/issues/7106.
* Remove redundant safety checks, refactor specs
* Add explicit note about how suggested users are used in onboarding
* Some configs_controller cleanup and fix copypasta in configs/show template
* Fetch SiteConfig.suggested_users via before_action
* Use presence instead of empty?
* Remove unnecessary .downcases from methods in Stories::Controller
* Removes .downcase from methods using params[:username]
* Removes .downcase from handle_user_or_organization_or_podcast_or_page_index
* Removes .downcase from handle_user_index
* Add shared_examples for lowercase routing to stories_index_spec.rb
* Replace create with build in stories_index_spec.rb
* Move onboarding-related configs into new onboarding section
* Extract mascot-related configs into a mascot section
* Update order of fields in SiteConfig model to match order in view
* Update ordering of specs for onboarding/mascot config changes
* Clear Elasticsearch Data Instead of Resetting Entire Index for Specs
* only reset for specs that are messing with index creation and deletion, recreate indexes before and after those
* add back elasticsearch meta info to specs and update data update specs
* update serializer specs
* update search and rest of specs with new meta data tag
* Rename remove_association to remove_identity and future proof its tests
* Use the signin_path everywhere
* Generalize account settings
* Use delegation
* Add route_downcaser gem to Gemfile to make routes case-insensitive
* Ensures paths are downcased and redirects to lowercase routes
* Resolves SEO issue where uppercase routes do not redirect to lowercase
* Add before_action to redirect to lowercase user routes
* Adds a before_action for the index only
* Redirects lowercase usernames and article titles
* Comments out route_downcaser gem in Gemfile for now
* Redirect to lowercase usernames in StoriesController#show for uppercase usernames
* Redirects in before_action for the index method only
* Adds nil check in #redirect_to_lowercase_username
* Adjusts stories_index_spec.rb to be more concise
* Removes old and unnecessary code from StoriesController and spec
* Add additional testing around lowercase name redirects and aggregate_failures
* Replace hardcoded URL with URL helper in Stories::Controller and stories_index_spec
* Fix GET request in stories_index_spec.rb
* Use upper in place of A-Z in regex in redirect_to_lowercase_username
* Revert URL helper changes and use params instead in Stories::Controller and stories_index_spec
* Use Devise registry to list available providers
* Cleanups following Devise+Omniauth docs
* More cleanups
* Use helpers
* More cleanups
* Oops, forgot to remove these specs
* Added configurable meta keywords
* Replaced hardcoded meta-keywords with the configurable ones
* Added tests for configurable meta_keywords
* Improve info for configuring meta-keywords
* add optional fields to user
- this provides the back-end implementation for #2365
* fix mistakes in schema.rb
* renamed OptionalField to userOptionalField
* rename field column in user_optional_fields to label
* add uniqueness validation on user_optional_field labels
* scope flag uniqueness to user_id
* add indexing on label in user_optional_fields
* add optional fields to user
- this provides the back-end implementation for #2365
* fix mistakes in schema.rb
* add index on user_id for user_optional_fields
* Remove duplicate model
* Fix schema
* Re-add past indexes
* Remove old index
* Remove another old index
* add `null:false` to columns in optional fields
* add `null: false` to the migration
- Updated test to account for the null constraint
* add null:false to user_id on user_optional_tables
Co-authored-by: rhymes <rhymesete@gmail.com>
Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
* feat: add base site config
* chore: rename developer/developers
* feat: update to use community_member_label
* chore: amend text
* chore: update spec
* chore: extra space
* feat: add placeholders for some routes
* about_listings_url
* feat: tag-moderation
* chore: about_listings_url test
* chore: use post a job url
* chore: add pages methods
* chore: just reordered stuff
* oops forgot to save - oh man
* chore: change to single quotes
* chore: hopefully retrigger cc
* chore: update tests
* feat: PR suggestions:)
* chore: spec