FIX: show cooked bio in user profile (#27734)

When editing your bio in your user profile and then saving it, it would be removed from the profile header section.

This was broken for over 7 years since ae68795d82 was merged 😅

Context - https://meta.discourse.org/t/after-saving-changes-to-profile-expanding-full-profile-only-shows-half/314118
This commit is contained in:
Régis Hanol
2024-07-05 12:31:57 +02:00
committed by GitHub
parent 92d7d24d0f
commit 1045d22b41
3 changed files with 35 additions and 13 deletions

View File

@@ -7,6 +7,18 @@ describe "User preferences | Profile", type: :system do
before { sign_in(user) }
describe "changing bio" do
it "correctly updates the bio" do
user_preferences_profile_page.visit(user)
user_preferences_profile_page.expand_profile_details
user_preferences_profile_page.fill_bio(with: "I am a human.")
user_preferences_profile_page.save
expect(user_preferences_profile_page.cooked_bio).to have_text("I am a human.")
end
end
describe "enforcing required fields" do
before do
UserRequiredFieldsVersion.create!