diff --git a/test/html/document_fragment_test.rb b/test/html/document_fragment_test.rb
index 848eff64..f4bccc26 100644
--- a/test/html/document_fragment_test.rb
+++ b/test/html/document_fragment_test.rb
@@ -549,6 +549,15 @@ class StimulusReflex::HTML::DocumentFragmentTest < ActiveSupport::TestCase
assert_equal %(), fragment.inner_html.squish
end
+ test "non-standard HTML attributes (Alpine.js-like)" do
+ html = %()
+
+ fragment = StimulusReflex::HTML::DocumentFragment.new(html)
+
+ assert_equal %(), fragment.to_html.squish
+ assert_equal %(), fragment.outer_html.squish
+ end
+
test "should extract a fragment of the HTML" do
raw_html = <<-HTML