aboutsummaryrefslogtreecommitdiffstats
path: root/test/CompilerSpec.js
diff options
context:
space:
mode:
authorMisko Hevery2010-03-23 14:57:11 -0700
committerMisko Hevery2010-03-23 14:57:11 -0700
commitbb98ae14f2aef74efbd8345e93f62ac67f460f7f (patch)
treeb50ac4417c7b1bda996dd569069d7eb834eef2ff /test/CompilerSpec.js
parent6ff550cfa9524bbb124d10caf1fc13c911ab3b4b (diff)
downloadangular.js-bb98ae14f2aef74efbd8345e93f62ac67f460f7f.tar.bz2
markup now wroks, some refactorings
Diffstat (limited to 'test/CompilerSpec.js')
-rw-r--r--test/CompilerSpec.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/test/CompilerSpec.js b/test/CompilerSpec.js
index 57b597c4..a49a2551 100644
--- a/test/CompilerSpec.js
+++ b/test/CompilerSpec.js
@@ -3,7 +3,7 @@ describe('compiler', function(){
return jQuery(html)[0];
}
- var compiler, markup, directives, widgets, compile, log;
+ var compiler, textMarkup, directives, widgets, compile, log;
beforeEach(function(){
log = "";
@@ -24,9 +24,10 @@ describe('compiler', function(){
}
};
- markup = [];
+ textMarkup = [];
+ attrMarkup = [];
widgets = {};
- compiler = new Compiler(markup, directives, widgets);
+ compiler = new Compiler(textMarkup, attrMarkup, directives, widgets);
compile = function(html){
var e = element("<div>" + html + "</div>");
var view = compiler.compile(e)(e);
@@ -108,7 +109,7 @@ describe('compiler', function(){
});
it('should process markup before directives', function(){
- markup.push(function(text, textNode, parentNode) {
+ textMarkup.push(function(text, textNode, parentNode) {
if (text == 'middle') {
expect(textNode.text()).toEqual(text);
parentNode.attr('hello', text);