chromium/third_party/blink/web_tests/editing/selection/extend/extend_selection_08_ltr_forward_lineboundary.html

<!doctype html>
<script src="../../../resources/testharness.js"></script>
<script src="../../../resources/testharnessreport.js"></script>
<script src="../../assert_selection.js"></script>
<script>
selection_test(
  '<div contenteditable dir="ltr">|Lorem <span dir="ltr">ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">^Lorem <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-0 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">L|orem <span dir="ltr">ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">L^orem <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-1 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lo|rem <span dir="ltr">ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lo^rem <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-2 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lor|em <span dir="ltr">ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lor^em <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-3 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lore|m <span dir="ltr">ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lore^m <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-4 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem| <span dir="ltr">ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem^ <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-5 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">|ipsum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">^ipsum dolor sit</span> amet|</div>',
  '8-6 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">i|psum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">i^psum dolor sit</span> amet|</div>',
  '8-7 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ip|sum dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ip^sum dolor sit</span> amet|</div>',
  '8-8 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ips|um dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ips^um dolor sit</span> amet|</div>',
  '8-9 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsu|m dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsu^m dolor sit</span> amet|</div>',
  '8-10 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum| dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum^ dolor sit</span> amet|</div>',
  '8-11 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum |dolor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum ^dolor sit</span> amet|</div>',
  '8-12 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum d|olor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum d^olor sit</span> amet|</div>',
  '8-13 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum do|lor sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum do^lor sit</span> amet|</div>',
  '8-14 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dol|or sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dol^or sit</span> amet|</div>',
  '8-15 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolo|r sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolo^r sit</span> amet|</div>',
  '8-16 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor| sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor^ sit</span> amet|</div>',
  '8-17 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor |sit</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor ^sit</span> amet|</div>',
  '8-18 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor s|it</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor s^it</span> amet|</div>',
  '8-19 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor si|t</span> amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor si^t</span> amet|</div>',
  '8-20 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span>| amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span>^ amet|</div>',
  '8-21 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> |amet</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> ^amet|</div>',
  '8-22 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> a|met</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> a^met|</div>',
  '8-23 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> am|et</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> am^et|</div>',
  '8-24 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> ame|t</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> ame^t|</div>',
  '8-25 ltr forward lineboundary');

selection_test(
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  selection => selection.modify('extend', 'forward', 'lineboundary'),
  '<div contenteditable dir="ltr">Lorem <span dir="ltr">ipsum dolor sit</span> amet|</div>',
  '8-26 ltr forward lineboundary');
</script>