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

Commit

Permalink
Merge pull request #10567 from adobe/pflynn/fix-unit-test
Browse files Browse the repository at this point in the history
Fix unit test that broke due to Find highlighting fix in PR #10413
  • Loading branch information
prksingh committed Feb 11, 2015
2 parents c1222f7 + 2a11d47 commit 97c3a4c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion test/spec/FindReplace-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,10 @@ define(function (require, exports, module) {
});
}

// Verify number of tickmarks equals number of highlights
var tickmarks = tw$(".tickmark-track .tickmark", myEditor.getRootElement());
expect(tickmarks.length).toEqual(selections.length);

// Verify that editor UI doesn't have extra ranges left highlighted from earlier
// (note: this only works for text that's short enough to not get virtualized)
var lineDiv = tw$(".CodeMirror-lines .CodeMirror-code", myEditor.getRootElement());
Expand Down Expand Up @@ -504,7 +508,8 @@ define(function (require, exports, module) {
enterSearchText("b");

expectMatchIndex(0, 2430);
expectHighlightedMatches([]);
// When exceeding 2000 matches, tickmarks disabled and only the *current* editor highlight is shown
expectHighlightedMatches([], 1);
});

it("should find all case-insensitive matches with lowercase text", function () {
Expand Down
2 changes: 1 addition & 1 deletion test/spec/WorkingSetView-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ define(function (require, exports, module) {
CommandManager.execute(Commands.FILE_RENAME);
});

waits(ProjectManager._RENDER_DEBOUNCE_TIME);
waits(ProjectManager._RENDER_DEBOUNCE_TIME + 50);

runs(function () {
expect($("#project-files-container ul input").val()).toBe(fileName);
Expand Down

0 comments on commit 97c3a4c

Please sign in to comment.