| OLD | NEW |
| 1 <!doctype html> | 1 <!doctype html> |
| 2 <script src="../resources/testharness.js"></script> | 2 <script src="../resources/testharness.js"></script> |
| 3 <script src="../resources/testharnessreport.js"></script> | 3 <script src="../resources/testharnessreport.js"></script> |
| 4 <script src="assert_selection.js"></script> | 4 <script src="assert_selection.js"></script> |
| 5 <div id="log"></div> | |
| 6 <script> | 5 <script> |
| 7 function checked_assert_selection(input, command, output) { | 6 function checked_assert_selection(input, command, output) { |
| 8 try { | 7 try { |
| 9 assert_selection(input, command, output); | 8 assert_selection(input, command, output); |
| 10 } catch (exception) { | 9 } catch (exception) { |
| 11 return exception.message; | 10 return exception.message; |
| 12 } | 11 } |
| 13 return 'no exception'; | 12 return 'no exception'; |
| 14 } | 13 } |
| 15 | 14 |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 test(() => { | 98 test(() => { |
| 100 assert_equals(checked_assert_selection('^|foo', 'noop', 'baz'), | 99 assert_equals(checked_assert_selection('^|foo', 'noop', 'baz'), |
| 101 'You should have focus marker and should not have anchor marker if and o
nly if selection is a caret in "^|foo".'); | 100 'You should have focus marker and should not have anchor marker if and o
nly if selection is a caret in "^|foo".'); |
| 102 }, 'anchor == foucs in input'); | 101 }, 'anchor == foucs in input'); |
| 103 | 102 |
| 104 test(() => { | 103 test(() => { |
| 105 assert_equals(checked_assert_selection('|foo', 'noop', 'b^|az'), | 104 assert_equals(checked_assert_selection('|foo', 'noop', 'b^|az'), |
| 106 'You should have focus marker and should not have anchor marker if and o
nly if selection is a caret in "b^|az".'); | 105 'You should have focus marker and should not have anchor marker if and o
nly if selection is a caret in "b^|az".'); |
| 107 }, 'anchor == foucs in output'); | 106 }, 'anchor == foucs in output'); |
| 108 </script> | 107 </script> |
| OLD | NEW |