diff options
Diffstat (limited to 'test')
| -rw-r--r-- | test/CompilerSpec.js | 2 | ||||
| -rw-r--r-- | test/ParserTest.js | 4 | ||||
| -rw-r--r-- | test/widgetsSpec.js | 28 | 
3 files changed, 33 insertions, 1 deletions
| diff --git a/test/CompilerSpec.js b/test/CompilerSpec.js index a49a2551..59b7ab6b 100644 --- a/test/CompilerSpec.js +++ b/test/CompilerSpec.js @@ -1,4 +1,4 @@ -describe('compiler', function(){ +xdescribe('compiler', function(){    function element(html) {      return jQuery(html)[0];    } diff --git a/test/ParserTest.js b/test/ParserTest.js index 53ca9eda..c8d323f2 100644 --- a/test/ParserTest.js +++ b/test/ParserTest.js @@ -482,3 +482,7 @@ ParserTest.prototype.testBugStringConfusesParser = function() {    assertEquals('!', scope.eval('suffix = "!"'));  }; +ParserTest.prototype.testParsingBug = function () { +  var scope = new Scope(); +  assertEquals({a: "-"}, scope.eval("{a:'-'}")); +}; diff --git a/test/widgetsSpec.js b/test/widgetsSpec.js new file mode 100644 index 00000000..3b6be8ec --- /dev/null +++ b/test/widgetsSpec.js @@ -0,0 +1,28 @@ +describe("widgets", function(){ + +  var compile, element, scope; + +  beforeEach(function() { +    scope = null; +    element = null; +    var compiler = new Compiler(angularTextMarkup, angularAttrMarkup, angularDirective, angularWidget); +    compile = function(html) { +      element = jqLite(html); +      var view = compiler.compile(element)(element); +      view.init(); +      scope = view.scope; +    }; +  }); + +  afterEach(function(){ +    if (element) { +      element.remove(); +    } +    expect(_(jqCache).size()).toEqual(0); +  }); + +  it('should fail', function(){ +    fail('iueoi'); +  }); + +}); | 
