diff --git a/lib/utopia/content/markup.rb b/lib/utopia/content/markup.rb index 3677cb7..85beebc 100644 --- a/lib/utopia/content/markup.rb +++ b/lib/utopia/content/markup.rb @@ -153,7 +153,7 @@ def instruction(string) end def cdata(string) - @delegate.write(string) + @delegate.text(string[9..-4]) end def text(string) diff --git a/test/utopia/content/markup.rb b/test/utopia/content/markup.rb index 8cde57f..2c7aaed 100644 --- a/test/utopia/content/markup.rb +++ b/test/utopia/content/markup.rb @@ -58,7 +58,7 @@ def parse(string) [:tag_begin, foo_tag], [:text, "Bob & Barley"], [:write, ""], - [:write, ""], + [:text, "Hello & World"], [:tag_end, foo_tag], ]