;
        }, "Directionality is updated when removing CDATASection");

        promise_test(async function() {
            let [div, cdata] = await createXHTMLCase(3);
            assert_true(div.matches(":dir(ltr)"));
            cdata.textContent = "اختبر";
            assert_true(div.matches(":dir(rtl)"));
        }, "Directionality is updated when changing text of CDATASection");
    </script>
</body>
</html>
