docbrown/spec/requests/admin
rhymes 99ddd31058
Pin posts to feed (#13807)
* Add SiteConfig.feed_pinned_article and validation

* Display pinned article at the top of feed

* Add (basic) functionality to pin/unpin post

* Admins can pin other users posts as well

* Hide the button if looking at the non pinned post

* Add pinned/unpinned snackbar message

* Rename SiteConfig usage to Settings::General

* Add pinned article to the Admin articles index

* Show the pin post button when there's no pinned article

* Move pinning to a separate controller

* Fix SiteConfig reference

* Hide PinController actions to unauthorized users

* PinnedArticlesController#show action and refactor some of the code

* Add Modal interaction

* Fix modal-pinned checkbox interaction

* Fixed pin/unpin post

* Add ArticleDecorator#pinned? specs

* Add PinnedArticlePolicy and PinnedArticlesController specs

* Add ability to actually pin an article from the admin after submit

* Add partial Cypress pin/unpin spec

* Fix pinned article and add basic Cypress interaction tests

* Add Crayons styling to modal

* Only render the pinned article on the default Feed page

* Use persisted?

* Add some comments

* Update app/javascript/articles/Article.jsx

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update app/javascript/packs/homePageFeed.jsx

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Fix Cypress tests

* Update app/javascript/admin/controllers/article_controller.js

Co-authored-by: Ridhwana <Ridhwana.Khan16@gmail.com>

* Fix pinning in article show page

* Used PinnedArticle domain model

* Fix spec

* Update cypress/integration/adminFlows/articles/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update cypress/integration/adminFlows/articles/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update cypress/integration/adminFlows/articles/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update cypress/integration/adminFlows/articles/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update cypress/integration/adminFlows/articles/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update cypress/integration/articleFlows/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update cypress/integration/articleFlows/pinArticle.spec.js

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Update app/views/admin/articles/index.html.erb

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Fix merge woes

* Add missing article pin post flows

* Add missing admin article flows

* Add Unpin to Admin as well

* Add Audit::Log entries for pin/unpin actions

* Update app/controllers/stories/feeds_controller.rb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Do not rate limit in E2E tests

* Use .find instead of .filter

* Rename ArticleIdValidator to ExistingArticleIdValidator

* Treat draft and deleted articles the same

* Make sure posts can be pinned after the pinned article is unpublished or deleted

* Use .get directly

* Fix spec and fix PinnedArticlesController#show

* Strengthen pinArticle Cypress tests

* Add Cypress test heading guard

* Add another Cypress test heading guard

* Remove duplicate validator

* Try using the Tools: header instead of the article title

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
Co-authored-by: Ridhwana <Ridhwana.Khan16@gmail.com>
Co-authored-by: Michael Kohl <citizen428@dev.to>
2021-06-04 10:54:53 +02:00
..
tags RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
users RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
articles_spec.rb Pin posts to feed (#13807) 2021-06-04 10:54:53 +02:00
badge_achievements_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
badges_spec.rb [15-min-fix] Remove badge slug field b/c auto-gen by title (#13649) 2021-05-05 13:49:43 -04:00
broadcasts_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
chat_channel_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
comments_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
configs_spec.rb Replacing granular admin email settings with one default email (#13853) 2021-05-28 12:17:08 +03:00
consumer_apps_spec.rb Have specs run without Redis and refactor ConsumerApp and Device (#13647) 2021-05-07 08:03:16 +02:00
data_update_scripts_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
display_ads_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
events_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
feedback_messages_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
html_variants_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
invitations_spec.rb [15-min-fix] Remove/Update the last of the admin hardcoded paths (#13681) 2021-05-06 15:12:06 +02:00
listings_categories_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
listings_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
moderator_actions_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
moderator_logs_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
mods_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
navigation_link_spec.rb Rename SiteConfig to Settings::General (#13573) 2021-05-21 14:45:37 +02:00
nested_sidebar_spec.rb chore: uncomment the test (#13658) 2021-05-05 19:00:15 +02:00
organizations_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
overview_spec.rb RFC 50 - Remove old admin routes and related code (#13579) 2021-05-03 16:03:38 +02:00
pages_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
permissions_spec.rb [15-min-fix] Remove/Update the last of the admin hardcoded paths (#13681) 2021-05-06 15:12:06 +02:00
podcasts_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
privileged_reactions_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
profile_field_groups_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
profile_fields_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
reactions_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
response_templates_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
secrets_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
sponsorships_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
tags_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
tools_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
users_manage_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00
users_spec.rb Clean up SiteConfig (#13738) 2021-05-18 09:38:31 +07:00
welcome_spec.rb RFC 50: Remove hardcoded paths and use path_helpers instead (in the specs) (#13549) 2021-04-28 21:32:51 +02:00