aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/content_test.rb10
1 files changed, 1 insertions, 9 deletions
diff --git a/test/unit/content_test.rb b/test/unit/content_test.rb
index 60fb39610b..59beb323cf 100644
--- a/test/unit/content_test.rb
+++ b/test/unit/content_test.rb
@@ -7,19 +7,11 @@ module ActionText
assert_equal "Hello world", message.content.body.to_plain_text
end
- test "creating a model with rich text content will not create a rich text record" do
+ test "without content" do
message = Message.create!(subject: "Greetings")
assert message.content.body.nil?
end
- test "removing content removes the rich text record" do
- message = Message.create!(subject: "Greetings", content: "<h1>Hello world</h1>")
-
- assert_difference -> { ActionText::RichText.all.count }, -1 do
- message.update!(content: "")
- end
- end
-
test "embed extraction" do
blob = create_file_blob(filename: "racecar.jpg", content_type: "image/jpg")
message = Message.create!(subject: "Greetings", content: ActionText::Content.new("Hello world").append_attachables(blob))