diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /testing/web-platform/tests/html/editing/editing-0 | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'testing/web-platform/tests/html/editing/editing-0')
11 files changed, 132 insertions, 0 deletions
diff --git a/testing/web-platform/tests/html/editing/editing-0/.gitkeep b/testing/web-platform/tests/html/editing/editing-0/.gitkeep new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/.gitkeep diff --git a/testing/web-platform/tests/html/editing/editing-0/best-practices-for-in-page-editors/.gitkeep b/testing/web-platform/tests/html/editing/editing-0/best-practices-for-in-page-editors/.gitkeep new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/best-practices-for-in-page-editors/.gitkeep diff --git a/testing/web-platform/tests/html/editing/editing-0/contenteditable/.gitkeep b/testing/web-platform/tests/html/editing/editing-0/contenteditable/.gitkeep new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/contenteditable/.gitkeep diff --git a/testing/web-platform/tests/html/editing/editing-0/contenteditable/contentEditable-invalidvalue.html b/testing/web-platform/tests/html/editing/editing-0/contenteditable/contentEditable-invalidvalue.html new file mode 100644 index 000000000..85b71043e --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/contenteditable/contentEditable-invalidvalue.html @@ -0,0 +1,16 @@ +<!DOCTYPE html> +<meta charset=utf-8> +<title>contentEditable setter: invalid value</title> +<link rel="author" title="Denis Ah-Kang" href="mailto:denis@w3.org"> +<link rel=help href="https://html.spec.whatwg.org/multipage/#contenteditable"> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> + var el = document.createElement("div"); + test(function(){ + assert_throws("SyntaxError", function() { + el.contentEditable = "foobar"; + }); + }, "setting contentEditable to an invalid value throws a SyntaxError Exception"); +</script> diff --git a/testing/web-platform/tests/html/editing/editing-0/contenteditable/user-interaction-editing-contenteditable.html b/testing/web-platform/tests/html/editing/editing-0/contenteditable/user-interaction-editing-contenteditable.html new file mode 100644 index 000000000..9ef867b2d --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/contenteditable/user-interaction-editing-contenteditable.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<html> + <head> + <title>Editing: contentEditable attribute test</title> + <link rel="author" title="Baidu" href="mailto: guopengcheng@baidu.com"/> + <link rel="help" href="https://html.spec.whatwg.org/multipage/#contenteditable"/> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <div id="log"></div> + </head> + <body> + <script type="text/javascript"> + var testElement = document.createElement("testElement"); + test(function() { + assert_equals(testElement.contentEditable,"inherit", "check for testElement.contentEditable value"); + }, "no contentEditable attribute"); + testElement.setAttribute("contentEditable", ""); + test(function() { + assert_true(testElement.isContentEditable, "check for testElement.isContentEditable value"); + assert_equals(testElement.contentEditable,"true", "check for testElement.contentEditable value"); + }, "empty contentEditable attribute"); + testElement.contentEditable="true"; + test(function() { + assert_true(testElement.isContentEditable, "check for testElement.isContentEditable value"); + assert_equals(testElement.contentEditable,"true", "check for testElement.contentEditable value"); + }, "set contentEditable = \"true\""); + testElement.contentEditable="false"; + test(function() { + assert_false(testElement.isContentEditable, "check for testElement.isContentEditable value"); + assert_equals(testElement.contentEditable,"false", "check for testElement.contentEditable value"); + }, "set contentEditable = \"false\""); + testElement.contentEditable="inherit"; + test(function() { + assert_equals(testElement.contentEditable,"inherit", "check for testElement.contentEditable value"); + }, "set contentEditable = \"inherit\""); + var childElement = document.createElement("childElement"); + testElement.appendChild(childElement); + testElement.contentEditable="true"; + test(function() { + assert_true(testElement.isContentEditable, "check for testElement.isContentEditable value"); + assert_equals(testElement.contentEditable,"true", "check for testElement.contentEditable value"); + assert_true(childElement.isContentEditable, "check for childElement.isContentEditable value"); + assert_equals(childElement.contentEditable,"inherit", "check for childElement.contentEditable value"); + }, "set parent element contentEditable = \"true\""); + testElement.contentEditable="false"; + test(function() { + assert_false(testElement.isContentEditable, "check for testElement.isContentEditable value"); + assert_equals(testElement.contentEditable,"false", "check for testElement.contentEditable value"); + assert_false(childElement.isContentEditable, "check for childElement.isContentEditable value"); + assert_equals(childElement.contentEditable,"inherit", "check for childElement.contentEditable value"); + }, "set parent element contentEditable = \"false\""); + </script> + </body> +</html> diff --git a/testing/web-platform/tests/html/editing/editing-0/editing-apis/.gitkeep b/testing/web-platform/tests/html/editing/editing-0/editing-apis/.gitkeep new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/editing-apis/.gitkeep diff --git a/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/.gitkeep b/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/.gitkeep new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/.gitkeep diff --git a/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/original-id.json b/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/original-id.json new file mode 100644 index 000000000..8b7c4b838 --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/original-id.json @@ -0,0 +1 @@ +{"original_id":"making-entire-documents-editable:-the-designmode-idl-attribute"}
\ No newline at end of file diff --git a/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/user-interaction-editing-designMode.html b/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/user-interaction-editing-designMode.html new file mode 100644 index 000000000..f73ea7326 --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/making-entire-documents-editable-the-designmode-idl-attribute/user-interaction-editing-designMode.html @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html> + <head> + <title>Editing: designMode attribute test</title> + <link rel="author" title="Baidu" href="mailto: guopengcheng@baidu.com"/> + <link rel="help" href="https://html.spec.whatwg.org/multipage/#making-entire-documents-editable:-the-designmode-idl-attribute"/> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <div id="log"></div> + </head> + <body> + <script type="text/javascript"> + test(function() { + assert_equals(document.designMode, "off", "check for designMode value"); + }, "initial designMode attribute"); + document.designMode="on"; + test(function() { + assert_equals(document.designMode, "on", "check for designMode value"); + }, "set designMode = \"on\""); + document.designMode="off"; + test(function() { + assert_equals(document.designMode,"off", "check for designMode value"); + }, "set designMode = \"off\""); + </script> + </body> +</html> diff --git a/testing/web-platform/tests/html/editing/editing-0/spelling-and-grammar-checking/.gitkeep b/testing/web-platform/tests/html/editing/editing-0/spelling-and-grammar-checking/.gitkeep new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/spelling-and-grammar-checking/.gitkeep diff --git a/testing/web-platform/tests/html/editing/editing-0/spelling-and-grammar-checking/user-interaction-editing-spellcheck.html b/testing/web-platform/tests/html/editing/editing-0/spelling-and-grammar-checking/user-interaction-editing-spellcheck.html new file mode 100644 index 000000000..c8bdaafdb --- /dev/null +++ b/testing/web-platform/tests/html/editing/editing-0/spelling-and-grammar-checking/user-interaction-editing-spellcheck.html @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html> + <head> + <title>Editing: spellcheck attribute test</title> + <link rel="author" title="Baidu" href="mailto: guopengcheng@baidu.com"/> + <link rel="help" href="https://html.spec.whatwg.org/multipage/#spelling-and-grammar-checking"/> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + </head> + <body> + <div id="log"></div> + <textarea id="testText1" spellcheck="true">Test textarea with spellcheck is true</textarea> + <textarea id="testText2" spellcheck="false">Test textarea with spellcheck is false</textarea> + <script type="text/javascript"> + test(function() { + assert_true(document.getElementById("testText1").spellcheck, "check for testText1 spellcheck value"); + assert_false(document.getElementById("testText2").spellcheck, "check for testText2 spellcheck value"); + }, "Getting spellcheck IDL attribute"); + test(function() { + var testElement = document.createElement("testElement"); + testElement.contentEditable = true; + testElement.spellcheck = true; + assert_true(testElement.spellcheck, "check for testElement.spellcheck value"); + assert_equals(testElement.getAttribute("spellcheck"), "true"); + }, "Setting spellcheck IDL attribute to true"); + test(function() { + var testElement = document.createElement("testElement"); + testElement.contentEditable = true; + testElement.spellcheck = false; + assert_false(testElement.spellcheck, "check for testText2 spellcheck value"); + assert_equals(testElement.getAttribute("spellcheck"), "false"); + }, "Setting spellcheck IDL attribute to false"); + </script> + </body> +</html> |