diff options
Diffstat (limited to 'tests/unit/autocomplete/autocomplete_methods.js')
-rw-r--r-- | tests/unit/autocomplete/autocomplete_methods.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/unit/autocomplete/autocomplete_methods.js b/tests/unit/autocomplete/autocomplete_methods.js index 5c20a6c95..05a7d6e14 100644 --- a/tests/unit/autocomplete/autocomplete_methods.js +++ b/tests/unit/autocomplete/autocomplete_methods.js @@ -13,8 +13,11 @@ module("autocomplete: methods", { test("destroy", function() { var beforeHtml = $("#autocomplete").parent().html(); var afterHtml = $("#autocomplete").autocomplete().autocomplete("destroy").parent().html(); - // TODO can't use same, as that would insert the markup unescaped into the test results, screwing up other tests - ok( beforeHtml == afterHtml ); + // Opera 9 outputs role="" instead of removing the attribute like everyone else + if ($.browser.opera) { + afterHtml = afterHtml.replace(/ role=""/g, ""); + } + equal( afterHtml, beforeHtml, "before/after html should be the same" ); }) var data = ["c++", "java", "php", "coldfusion", "javascript", "asp", "ruby", "python", "c", "scala", "groovy", "haskell", "perl"]; |