improve CSS and HTML auto indent

This commit is contained in:
Fabian Jakobs 2010-04-20 12:06:47 +02:00
commit ba025f3e87
10 changed files with 132 additions and 19 deletions

23
test/mode/TextTest.js Normal file
View file

@ -0,0 +1,23 @@
var TextTest = new TestCase("mode.TextTest", {
setUp : function() {
this.mode = new ace.mode.Text();
},
"test: toggle comment lines should not do anything" : function() {
var doc = new ace.TextDocument([" abc", "cde", "fg"].join("\n"));
var range = {
start: {row: 0, column: 3},
end: {row: 1, column: 1}
};
var comment = this.mode.toggleCommentLines(doc, range, "start");
assertEquals([" abc", "cde", "fg"].join("\n"), doc.toString());
},
"text: lines should not be indented" : function() {
assertEquals("", this.mode.getNextLineIndent(" abc", " "));
}
});