Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Unified Diff: third_party/WebKit/LayoutTests/fast/dnd/dropEffect-for-effectAllowed.html

Issue 2720463002: Remove webkitdropzone. (Closed)
Patch Set: Finished rewriting dropzone tests. Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/fast/dnd/dropEffect-for-effectAllowed.html
diff --git a/third_party/WebKit/LayoutTests/fast/dnd/dropEffect-for-effectAllowed.html b/third_party/WebKit/LayoutTests/fast/dnd/dropEffect-for-effectAllowed.html
new file mode 100644
index 0000000000000000000000000000000000000000..7d23c0304ff9262115a5b99aacefa7f1e561ace2
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/dnd/dropEffect-for-effectAllowed.html
@@ -0,0 +1,102 @@
+<!doctype html>
+<meta charset="utf-8" />
jsbell 2017/03/02 22:06:45 nit: no /> just > unless this is XHTML (which it i
pwnall 2017/03/02 22:34:29 Done.
+<title>Drag and Drop: interaction between effectAllowed and dropEffect</title>
+<link rel="help" href="https://html.spec.whatwg.org/multipage/interaction.html#drag-and-drop-processing-model">
+<script src="../../resources/testharness.js"></script>
+<script src="../../resources/testharnessreport.js"></script>
+<script src="resources/dropEffect-common.js"></script>
+<style>
+.box {
+ display: block;
+ border: 1px solid black;
+ width: 100px;
+ height: 100px;
+}
+</style>
+
+<p>
+ Please drag the "Drag Me" box into the "Drop Here" box repeatedly, until the
+ test ends.
+</p>
+
+<div class="dragged box" draggable="true">
+ Drag Me
+</div>
+
+<div class="dropzone box">
+ Drop Here
+</div>
+
+<p>
+ Current test: <code class="test-description"></code>
jsbell 2017/03/02 22:06:45 nit: Weird to use a class rather than an id for a
pwnall 2017/03/02 22:34:29 Done.
+</p>
+
+<script>
+
+dropEffectTest({ allowed: 'uninitialized', drop: 'copy', operation: 'copy' });
+dropEffectTest({ allowed: 'copy', drop: 'copy', operation: 'copy' });
+dropEffectTest({ allowed: 'copyLink', drop: 'copy', operation: 'copy' });
+dropEffectTest({ allowed: 'copyMove', drop: 'copy', operation: 'copy' });
+dropEffectTest({ allowed: 'link', drop: 'copy' });
+dropEffectTest({ allowed: 'linkMove', drop: 'copy' });
+dropEffectTest({ allowed: 'move', drop: 'copy' });
+dropEffectTest({ allowed: 'all', drop: 'copy', operation: 'copy' });
+dropEffectTest({ allowed: 'none', drop: 'copy' });
+dropEffectTest({ allowed: 'dummy', drop: 'copy', operation: 'copy' });
+dropEffectTest({ drop: 'copy', operation: 'copy' });
+
+dropEffectTest({ allowed: 'uninitialized', drop: 'link', operation: 'link' });
+dropEffectTest({ allowed: 'copy', drop: 'link' });
+dropEffectTest({ allowed: 'copyLink', drop: 'link', operation: 'link' });
+dropEffectTest({ allowed: 'copyMove', drop: 'link' });
+dropEffectTest({ allowed: 'link', drop: 'link', operation: 'link' });
+dropEffectTest({ allowed: 'linkMove', drop: 'link', operation: 'link' });
+dropEffectTest({ allowed: 'move', drop: 'link' });
+dropEffectTest({ allowed: 'all', drop: 'link', operation: 'link' });
+dropEffectTest({ allowed: 'none', drop: 'link' });
+dropEffectTest({ allowed: 'dummy', drop: 'link', operation: 'link' });
+dropEffectTest({ drop: 'link', operation: 'link' });
+
+dropEffectTest({ allowed: 'uninitialized', drop: 'move', operation: 'move' });
+dropEffectTest({ allowed: 'copy', drop: 'move' });
+dropEffectTest({ allowed: 'copyLink', drop: 'move' });
+dropEffectTest({ allowed: 'copyMove', drop: 'move', operation: 'move' });
+dropEffectTest({ allowed: 'link', drop: 'move' });
+dropEffectTest({ allowed: 'linkMove', drop: 'move', operation: 'move' });
+dropEffectTest({ allowed: 'move', drop: 'move', operation: 'move' });
+dropEffectTest({ allowed: 'all', drop: 'move', operation: 'move' });
+dropEffectTest({ allowed: 'none', drop: 'move' });
+dropEffectTest({ allowed: 'dummy', drop: 'move', operation: 'move' });
+dropEffectTest({ drop: 'move', operation: 'move' });
+
+dropEffectTest({ allowed: 'uninitialized', drop: 'none' });
dcheng 2017/03/02 19:24:33 I'm not quite sure how to map this to the results
pwnall 2017/03/02 19:57:54 The results are different because "dropzone" does
+dropEffectTest({ allowed: 'copy', drop: 'none' });
+dropEffectTest({ allowed: 'copyLink', drop: 'none' });
+dropEffectTest({ allowed: 'copyMove', drop: 'none' });
+dropEffectTest({ allowed: 'link', drop: 'none' });
+dropEffectTest({ allowed: 'linkMove', drop: 'none' });
+dropEffectTest({ allowed: 'move', drop: 'none' });
+dropEffectTest({ allowed: 'all', drop: 'none' });
+dropEffectTest({ allowed: 'none', drop: 'none' });
+dropEffectTest({ allowed: 'dummy', drop: 'none' });
+dropEffectTest({ drop: 'none' });
+
+dropEffectTest({ allowed: 'uninitialized', drop: 'dummy', operation: 'copy' });
+dropEffectTest({ allowed: 'copy', drop: 'dummy', operation: 'copy' });
+dropEffectTest({ allowed: 'copyLink', drop: 'dummy', operation: 'copy' });
+dropEffectTest({ allowed: 'copyMove', drop: 'dummy', operation: 'move' });
+dropEffectTest({ allowed: 'link', drop: 'dummy', operation: 'link' });
+dropEffectTest({ allowed: 'linkMove', drop: 'dummy', operation: 'move' });
+dropEffectTest({ allowed: 'move', drop: 'dummy', operation: 'move' });
+dropEffectTest({ allowed: 'all', drop: 'dummy', operation: 'copy' });
+dropEffectTest({ allowed: 'none', drop: 'dummy' });
+dropEffectTest({ allowed: 'dummy', drop: 'dummy', operation: 'copy' });
+dropEffectTest({ drop: 'dummy', operation: 'copy' });
+
+promise_test(t => {
jsbell 2017/03/02 22:06:45 Since this pattern repeats across the test files,
pwnall 2017/03/02 22:34:29 Done.
+ return Promise.resolve().then(() => {
+ document.querySelector('.test-description').textContent = 'done';
+ });
+}, 'all tests complete');
+
+</script>

Powered by Google App Engine
This is Rietveld 408576698