Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Commit 1d25556

Browse files
author
Narciso Jaramillo
committed
Merge pull request #6773 from adobe/randy/cmv4-find-tests
Fix remaining cmv4 FindReplace unit tests
2 parents 5ce3f1a + d94feb3 commit 1d25556

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/search/FindReplace.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ define(function (require, exports, module) {
376376
// start with a pre-populated search and enter an additional character,
377377
// it will extend the initial selection instead of jumping to the next
378378
// occurrence.
379-
state.searchStartPos = editor.getCursorPos(true);
379+
state.searchStartPos = editor.getCursorPos(false, "start");
380380

381381
// If a previous search/replace bar was open, capture its query text for use below
382382
var initialQuery;

test/spec/FindReplace-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ define(function (require, exports, module) {
100100

101101
// Verify that editor UI doesn't have extra ranges left highlighted from earlier
102102
// (note: this only works for text that's short enough to not get virtualized)
103-
var lineDiv = tw$(".CodeMirror-lines > div", myEditor.getRootElement()).children()[2];
103+
var lineDiv = tw$(".CodeMirror-lines .CodeMirror-code", myEditor.getRootElement());
104104
var actualHighlights = tw$(".CodeMirror-searching", lineDiv);
105105
if (expectedDOMHighlightCount === undefined) {
106106
expectedDOMHighlightCount = selections.length;

0 commit comments

Comments
 (0)