require 'test_helper' class NoteSanitizerTest < ActiveSupport::TestCase context "Sanitizing a note" do should "strip unsafe tags" do body = '
test
' assert_equal('test
alert("owned")', NoteSanitizer.sanitize(body)) end should "strip unsafe css" do body = 'test
' assert_equal("test
", NoteSanitizer.sanitize(body)) end end end