diff --git a/actiontext/lib/action_text/engine.rb b/actiontext/lib/action_text/engine.rb index 0f55d460a1..8749498158 100644 --- a/actiontext/lib/action_text/engine.rb +++ b/actiontext/lib/action_text/engine.rb @@ -29,6 +29,10 @@ module ActionText def attachable_plain_text_representation(caption = nil) "[#{caption || filename}]" end + + def to_trix_content_attachment_partial_path + nil + end end end diff --git a/actiontext/test/unit/attachment_test.rb b/actiontext/test/unit/attachment_test.rb index 54831a0271..9ed1967450 100644 --- a/actiontext/test/unit/attachment_test.rb +++ b/actiontext/test/unit/attachment_test.rb @@ -32,8 +32,8 @@ class ActionText::AttachmentTest < ActiveSupport::TestCase assert_equal attachable.byte_size, trix_attachment.attributes["filesize"] assert_equal "Captioned", trix_attachment.attributes["caption"] - assert_not_nil attachable.to_trix_content_attachment_partial_path - assert_not_nil trix_attachment.attributes["content"] + assert_nil attachable.to_trix_content_attachment_partial_path + assert_nil trix_attachment.attributes["content"] end test "converts to TrixAttachment with content" do