Fixed TTS-1875 by moving dnd 5 TCs from delta to tct-dnd-html5-tests
authorLiu, Xin <xinx.liu@intel.com>
Wed, 14 Aug 2013 12:00:53 +0000 (20:00 +0800)
committerwanmingx.lin <wanmingx.lin@intel.com>
Wed, 14 Aug 2013 12:22:30 +0000 (20:22 +0800)
Signed-off-by: Liu, Xin <xinx.liu@intel.com>
14 files changed:
tct-dnd-html5-tests/configure.ac
tct-dnd-html5-tests/dnd/Makefile.am
tct-dnd-html5-tests/dnd/images/COPYING [new file with mode: 0644]
tct-dnd-html5-tests/dnd/images/Makefile.am [new file with mode: 0644]
tct-dnd-html5-tests/dnd/images/blue.png [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/COPYING [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/Makefile.am [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/dragdrop_004.htm [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/dragdrop_005.htm [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/dragdrop_006.htm [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/dragdrop_007.htm [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/dragdrop_008.htm [new file with mode: 0644]
tct-dnd-html5-tests/dnd/w3c/dragdrop_support.js [new file with mode: 0644]
tct-dnd-html5-tests/tests.xml

index 341160591b33a55948ca3ca1903e17c4ed2d6106..8b1a90103ad698f2ecabddca6e943f9e1e7fc022 100644 (file)
@@ -3,5 +3,7 @@ AM_INIT_AUTOMAKE([-Wall -Werror foreign])
 
 AC_CONFIG_FILES([Makefile \
 dnd/Makefile \
+dnd/w3c/Makefile \
+dnd/images/Makefile \
 common/Makefile resources/Makefile testkit/Makefile])
 AC_OUTPUT
index 06891ac5ad7452ba258e1686b474f109807da887..f8517398b9ec96e7cac30971b99712a7013aac03 100644 (file)
@@ -1,3 +1,4 @@
+SUBDIRS = w3c images
 DnD_SCRIPTS = *
 DnDdir = /opt/tct-dnd-html5-tests/dnd
 EXTRA_DIST = $(DnD_SCRIPTS)
diff --git a/tct-dnd-html5-tests/dnd/images/COPYING b/tct-dnd-html5-tests/dnd/images/COPYING
new file mode 100644 (file)
index 0000000..de0ccf6
--- /dev/null
@@ -0,0 +1,10 @@
+The blue.png file under this folder come from https://github.com/w3c/web-platform-tests/tree/master/old-tests/submission/Microsoft/images/ without any modification.
+
+The blue.png file is copyright by W3C and/or the author listed in the test
+file. The tests are dual-licensed under the W3C Test Suite License:
+http://www.w3.org/Consortium/Legal/2008/04-testsuite-license
+and the BSD 3-clause License:
+http://www.w3.org/Consortium/Legal/2008/03-bsd-license
+under W3C's test suite licensing policy:
+http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright
+
diff --git a/tct-dnd-html5-tests/dnd/images/Makefile.am b/tct-dnd-html5-tests/dnd/images/Makefile.am
new file mode 100644 (file)
index 0000000..bfb5717
--- /dev/null
@@ -0,0 +1,3 @@
+dndimages_SCRIPTS = *
+dndimagesdir = /opt/tct-dnd-html5-tests/dnd/images
+EXTRA_DIST = $(dndimages_SCRIPTS)
diff --git a/tct-dnd-html5-tests/dnd/images/blue.png b/tct-dnd-html5-tests/dnd/images/blue.png
new file mode 100644 (file)
index 0000000..4498dd2
Binary files /dev/null and b/tct-dnd-html5-tests/dnd/images/blue.png differ
diff --git a/tct-dnd-html5-tests/dnd/w3c/COPYING b/tct-dnd-html5-tests/dnd/w3c/COPYING
new file mode 100644 (file)
index 0000000..6232633
--- /dev/null
@@ -0,0 +1,12 @@
+This test suite comes from
+https://github.com/w3c/web-platform-tests
+without any modification except necessary adjustment on reference path
+to test harness.
+
+These tests are copyright by W3C and/or the author listed in the test
+file. The tests are dual-licensed under the W3C Test Suite License:
+http://www.w3.org/Consortium/Legal/2008/04-testsuite-license
+and the BSD 3-clause License:
+http://www.w3.org/Consortium/Legal/2008/03-bsd-license
+under W3C's test suite licensing policy:
+http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright
diff --git a/tct-dnd-html5-tests/dnd/w3c/Makefile.am b/tct-dnd-html5-tests/dnd/w3c/Makefile.am
new file mode 100644 (file)
index 0000000..9bb1da2
--- /dev/null
@@ -0,0 +1,3 @@
+DnDw3c_SCRIPTS = *
+DnDw3cdir = /opt/tct-dnd-html5-tests/dnd/w3c
+EXTRA_DIST = $(DnDw3c_SCRIPTS)
diff --git a/tct-dnd-html5-tests/dnd/w3c/dragdrop_004.htm b/tct-dnd-html5-tests/dnd/w3c/dragdrop_004.htm
new file mode 100644 (file)
index 0000000..eb129b4
--- /dev/null
@@ -0,0 +1,19 @@
+<!doctype html>
+<html>
+    <head>
+        <title>HTML5 Drag and Drop: Auto state of draggable attribute for 'a' element</title>
+        <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
+        <link rel="author" title="Microsoft" href="http://www.microsoft.com/"/>
+        <link rel="help" href="http://dev.w3.org/html5/spec/dnd.html#the-draggable-attribute"/>
+        <meta name="assert" content="Auto state of draggable attribute for 'a' element"/>
+        <script src="../../resources/testharness.js"></script>
+        <script src="../../resources/testharnessreport.js"></script>
+    </head>
+    <body>
+        <div id=log></div>
+        <a href="#" style="display:none" id="target">Drag this</a>
+        <script type="text/javascript">
+            test(function() {assert_true(document.getElementById("target").draggable)}, "Auto state of draggable attribute for 'a' element");
+        </script>
+    </body>
+</html>
diff --git a/tct-dnd-html5-tests/dnd/w3c/dragdrop_005.htm b/tct-dnd-html5-tests/dnd/w3c/dragdrop_005.htm
new file mode 100644 (file)
index 0000000..874f3ae
--- /dev/null
@@ -0,0 +1,19 @@
+<!doctype html>
+<html>
+    <head>
+        <title>HTML5 Drag and Drop: Auto state of draggable attribute for div element</title>
+        <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
+        <link rel="author" title="Microsoft" href="http://www.microsoft.com/"/>
+        <link rel="help" href="http://dev.w3.org/html5/spec/dnd.html#the-draggable-attribute"/>
+        <meta name="assert" content="Auto state of draggable attribute for div element"/>
+        <script src="../../resources/testharness.js"></script>
+        <script src="../../resources/testharnessreport.js"></script>
+    </head>
+    <body>
+        <div id=log></div>
+        <div style="border:2px red solid; width:200px; height:50px; display:none;"  id="target">SampleText</div>
+        <script type="text/javascript">
+            test(function() {assert_false(document.getElementById("target").draggable)}, "Auto state of draggable attribute for div element");
+        </script>
+    </body>
+</html>
diff --git a/tct-dnd-html5-tests/dnd/w3c/dragdrop_006.htm b/tct-dnd-html5-tests/dnd/w3c/dragdrop_006.htm
new file mode 100644 (file)
index 0000000..42d27b4
--- /dev/null
@@ -0,0 +1,19 @@
+<!doctype html>
+<html>
+    <head>
+        <title>HTML5 Drag and Drop: Auto state of draggable attribute for img element</title>
+        <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
+        <link rel="author" title="Microsoft" href="http://www.microsoft.com/"/>
+        <link rel="help" href="http://dev.w3.org/html5/spec/dnd.html#the-draggable-attribute"/>
+        <meta name="assert" content="Auto state of draggable attribute for img element"/>
+        <script src="../../resources/testharness.js"></script>
+        <script src="../../resources/testharnessreport.js"></script>
+    </head>
+    <body>
+        <div id=log></div>
+        <img style="width:200px; height:100px; display:none;" id="target"/>
+        <script type="text/javascript">
+            test(function() {assert_true(document.getElementById("target").draggable)}, "Auto state of draggable attribute for img element");
+        </script>
+    </body>
+</html>
diff --git a/tct-dnd-html5-tests/dnd/w3c/dragdrop_007.htm b/tct-dnd-html5-tests/dnd/w3c/dragdrop_007.htm
new file mode 100644 (file)
index 0000000..822a1e7
--- /dev/null
@@ -0,0 +1,19 @@
+<!doctype html>
+<html>
+    <head>
+        <title>HTML5 Drag and Drop: False state of draggable attribute</title>
+        <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
+        <link rel="author" title="Microsoft" href="http://www.microsoft.com/"/>
+        <link rel="help" href="http://dev.w3.org/html5/spec/dnd.html#the-draggable-attribute"/>
+        <meta name="assert" content="False state of draggable attribute"/>
+        <script src="../../resources/testharness.js"></script>
+        <script src="../../resources/testharnessreport.js"></script>
+    </head>
+    <body>
+        <div id=log></div>
+        <a href="#" style="display:none" id="target" draggable="false">Drag this</a>
+        <script type="text/javascript">
+            test(function() {assert_false(document.getElementById("target").draggable)}, "False state of draggable attribute");
+        </script>
+    </body>
+</html>
diff --git a/tct-dnd-html5-tests/dnd/w3c/dragdrop_008.htm b/tct-dnd-html5-tests/dnd/w3c/dragdrop_008.htm
new file mode 100644 (file)
index 0000000..fa0377a
--- /dev/null
@@ -0,0 +1,19 @@
+<!doctype html>
+<html>
+    <head>
+        <title>HTML5 Drag and Drop: True state of draggable attribute</title>
+        <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
+        <link rel="author" title="Microsoft" href="http://www.microsoft.com/"/>
+        <link rel="help" href="http://dev.w3.org/html5/spec/dnd.html#the-draggable-attribute"/>
+        <meta name="assert" content="True state of draggable attribute"/>
+        <script src="../../resources/testharness.js"></script>
+        <script src="../../resources/testharnessreport.js"></script>
+    </head>
+    <body>
+        <div id=log></div>
+        <a href="#" style="display:none" id="target" draggable="true">Drag this</a>
+        <script type="text/javascript">
+            test(function() {assert_true(document.getElementById("target").draggable)}, "True state of draggable attribute");
+        </script>
+    </body>
+</html>
diff --git a/tct-dnd-html5-tests/dnd/w3c/dragdrop_support.js b/tct-dnd-html5-tests/dnd/w3c/dragdrop_support.js
new file mode 100644 (file)
index 0000000..f5a1d64
--- /dev/null
@@ -0,0 +1,9 @@
+function AddEventListenersForElement(evt, callback, capture, element)
+{
+    element.addEventListener(evt, callback, capture);
+}
+
+function LogTestResult(result)
+{
+    document.getElementById("test_result").firstChild.data = result;
+}
index d48591d4b9226f88a0090efaad73e8c4807949df..3f988488af4897ff69bfaeff1c734db56932104a 100644 (file)
           </spec>
         </specs>
       </testcase>
+      <testcase purpose="Check false state of draggable attribute" type="compliance" status="approved" component="WebAPI/UI/HTML5 Drag and drop" execution_type="auto" priority="P2" id="dragdrop_007">
+        <description>
+          <pre_condition/>
+          <post_condition/>
+          <steps>
+            <step order="1">
+              <step_desc>Please refer to DnD/README</step_desc>
+              <expected>Pass</expected>
+            </step>
+          </steps>
+          <test_script_entry>/opt/tct-dnd-html5-tests/dnd/w3c/dragdrop_007.htm</test_script_entry>
+        </description>
+        <specs>
+          <spec>
+            <spec_assertion element_type="attribute" element_name="draggable" interface="HTMLElement" specification="HTML5 Drag and drop" section="UI" category="Tizen W3C API Specifications"/>
+            <spec_url>http://www.w3.org/TR/2012/WD-html5-20120329/dnd.html#the-draggable-attribute</spec_url>
+            <spec_statement/>
+          </spec>
+        </specs>
+      </testcase>
+      <testcase purpose="Check true state of draggable attribute" type="compliance" status="approved" component="WebAPI/UI/HTML5 Drag and drop" execution_type="auto" priority="P2" id="dragdrop_008">
+        <description>
+          <pre_condition/>
+          <post_condition/>
+          <steps>
+            <step order="1">
+              <step_desc>Please refer to DnD/README</step_desc>
+              <expected>Pass</expected>
+            </step>
+          </steps>
+          <test_script_entry>/opt/tct-dnd-html5-tests/dnd/w3c/dragdrop_008.htm</test_script_entry>
+        </description>
+        <specs>
+          <spec>
+            <spec_assertion element_type="attribute" element_name="draggable" interface="HTMLElement" specification="HTML5 Drag and drop" section="UI" category="Tizen W3C API Specifications"/>
+            <spec_url>http://www.w3.org/TR/2012/WD-html5-20120329/dnd.html#the-draggable-attribute</spec_url>
+            <spec_statement/>
+          </spec>
+        </specs>
+      </testcase>
+      <testcase purpose="Check auto state of draggable attribute for 'a' element" type="compliance" status="approved" component="WebAPI/UI/HTML5 Drag and drop" execution_type="auto" priority="P3" id="dragdrop_004">
+        <description>
+          <pre_condition/>
+          <post_condition/>
+          <steps>
+            <step order="1">
+              <step_desc>Please refer to DnD/README</step_desc>
+              <expected>Pass</expected>
+            </step>
+          </steps>
+          <test_script_entry>/opt/tct-dnd-html5-tests/dnd/w3c/dragdrop_004.htm</test_script_entry>
+        </description>
+        <specs>
+          <spec>
+            <spec_assertion usage="true" interface="HTMLElement" specification="HTML5 Drag and drop" section="UI" category="Tizen W3C API Specifications"/>
+            <spec_url>http://www.w3.org/TR/2012/WD-html5-20120329/dnd.html#the-draggable-attribute</spec_url>
+            <spec_statement/>
+          </spec>
+        </specs>
+      </testcase>
+      <testcase purpose="Check auto state of draggable attribute for div element" type="compliance" status="approved" component="WebAPI/UI/HTML5 Drag and drop" execution_type="auto" priority="P3" id="dragdrop_005">
+        <description>
+          <pre_condition/>
+          <post_condition/>
+          <steps>
+            <step order="1">
+              <step_desc>Please refer to DnD/README</step_desc>
+              <expected>Pass</expected>
+            </step>
+          </steps>
+          <test_script_entry>/opt/tct-dnd-html5-tests/dnd/w3c/dragdrop_005.htm</test_script_entry>
+        </description>
+        <specs>
+          <spec>
+            <spec_assertion usage="true" interface="HTMLElement" specification="HTML5 Drag and drop" section="UI" category="Tizen W3C API Specifications"/>
+            <spec_url>http://www.w3.org/TR/2012/WD-html5-20120329/dnd.html#the-draggable-attribute</spec_url>
+            <spec_statement/>
+          </spec>
+        </specs>
+      </testcase>
+      <testcase purpose="Check auto state of draggable attribute for img element" type="compliance" status="approved" component="WebAPI/UI/HTML5 Drag and drop" execution_type="auto" priority="P3" id="dragdrop_006">
+        <description>
+          <pre_condition/>
+          <post_condition/>
+          <steps>
+            <step order="1">
+              <step_desc>Please refer to DnD/README</step_desc>
+              <expected>Pass</expected>
+            </step>
+          </steps>
+          <test_script_entry>/opt/tct-dnd-html5-tests/dnd/w3c/dragdrop_006.htm</test_script_entry>
+        </description>
+        <specs>
+          <spec>
+            <spec_assertion usage="true" interface="HTMLElement" specification="HTML5 Drag and drop" section="UI" category="Tizen W3C API Specifications"/>
+            <spec_url>http://www.w3.org/TR/2012/WD-html5-20120329/dnd.html#the-draggable-attribute</spec_url>
+            <spec_statement/>
+          </spec>
+        </specs>
+      </testcase>
     </set>
   </suite>
 </test_definition>