Index: third_party/WebKit/LayoutTests/editing/selection/dont-select-text-overflow-ellipsis-when-wrapping.html |
diff --git a/third_party/WebKit/LayoutTests/editing/selection/dont-select-text-overflow-ellipsis-when-wrapping.html b/third_party/WebKit/LayoutTests/editing/selection/dont-select-text-overflow-ellipsis-when-wrapping.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..c8c5dd4fd2752000e4b72305c1688bc88c91752b |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/editing/selection/dont-select-text-overflow-ellipsis-when-wrapping.html |
@@ -0,0 +1,26 @@ |
+<!DOCTYPE html> |
+<meta charset=utf-8> |
+<style> |
+dl { |
+ max-width: 20em; |
+ margin: auto; |
+ font-size: 120%; |
+ white-space: nowrap; |
+} |
+dd { |
+ overflow: hidden; |
+ text-overflow: ellipsis; |
+ text-decoration: inherit; |
+} |
+</style> |
+<p>crbug.com/642454: Don't select part of the ellipsis when wrapping selection.</p> |
+<dl> |
+ <dd id="selection_with_ellipsis">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.</dd> |
+ <dt id="wrapped">Lorem ipsum dolor sit amet</dt> |
+</dl> |
+<script src="../../resources/run-after-layout-and-paint.js"></script> |
+<script> |
+runAfterLayoutAndPaint(function() { |
+ getSelection().setBaseAndExtent(selection_with_ellipsis.firstChild, 0, wrapped.firstChild, 10); |
+ }, true); |
+</script> |