occur+isearch: fixing tests

This commit is contained in:
Robert Krahn 2013-03-28 14:21:12 -07:00
commit 227f500a2c
2 changed files with 5 additions and 5 deletions

View file

@ -33,7 +33,7 @@ define(function(require, exports, module) {
var config = require("../config");
var oop = require("../lib/oop");
var HashHandler = require("../keyboard/hash_handler").HashHandler;
var occurStartCommand = require("ace/commands/occur_commands").occurStartCommand;
var occurStartCommand = require("./occur_commands").occurStartCommand;
// These commands can be installed in a normal key handler to start iSearch:
exports.iSearchStartCommands = [{

View file

@ -41,7 +41,7 @@ var MockRenderer = require("./test/mockrenderer").MockRenderer;
var Range = require("./range").Range;
var assert = require("./test/assertions");
var Occur = require("./occur").Occur;
var occurCommands = require("./commands/occur_commands").commands;
var occurStartCommand = require("./commands/occur_commands").occurStartCommand;
var editor, occur;
module.exports = {
@ -83,7 +83,7 @@ module.exports = {
// setup
var text = 'hel\nlo\n\nwo\nrld\n';
editor.session.insert({row: 0, column: 0}, text);
editor.commands.addCommands(occurCommands);
editor.commands.addCommand(occurStartCommand);
// run occur for lines including 'o'
editor.execCommand('occur', {needle: 'o'});
@ -107,7 +107,7 @@ module.exports = {
// setup
var text = 'hel\nlo\n\nwo\nrld\n';
editor.session.insert({row: 0, column: 0}, text);
editor.commands.addCommands(occurCommands);
editor.commands.addCommand(occurStartCommand);
editor.moveCursorToPosition({row: 1, column: 1});
// run occur for lines including 'o'
@ -126,7 +126,7 @@ module.exports = {
// setup
var text = 'x\nabc1\nx\nabc2\n';
editor.session.insert({row: 0, column: 0}, text);
editor.commands.addCommands(occurCommands);
editor.commands.addCommand(occurStartCommand);
// orig -> occur1
editor.execCommand('occur', {needle: 'abc'});