Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
antopalidi committed Jan 9, 2025
1 parent 3c6fc39 commit 56bfd7e
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions spec/system/public/edit_proposal_custom_fields_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,12 @@
expect(page).to have_no_content("Phone Number") # private field
expect(page).to have_no_content("555-555-555")

expect(model.reload.body["en"]).to include("I shot everything") unless amended
expect(Decidim::Proposals::Proposal.last.body["en"]).to include("I shot everything") if amended
expect(model.reload.body["en"]).to include("I shot the sheriff") if amended
if amended
expect(Decidim::Proposals::Proposal.last.body["en"]).to include("I shot everything")
expect(Decidim::Proposals::Proposal.last.private_body).to include('<dd id="text-1476748004579" name="text"><div>555-555-555</div></dd>')
else
expect(model.reload.private_body).to include('<dd id="text-1476748004579" name="text"><div>555-555-555</div></dd>')
end
end
end

Expand Down

0 comments on commit 56bfd7e

Please sign in to comment.