From 35a91085004e31f786df1e0011bc26ed0142ab4d Mon Sep 17 00:00:00 2001 From: Misko Hevery Date: Wed, 31 Mar 2010 13:57:25 -0700 Subject: all tests green, some dissabled --- test/moveToAngularCom/MiscTest.js | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 test/moveToAngularCom/MiscTest.js (limited to 'test/moveToAngularCom') diff --git a/test/moveToAngularCom/MiscTest.js b/test/moveToAngularCom/MiscTest.js new file mode 100644 index 00000000..db6e8563 --- /dev/null +++ b/test/moveToAngularCom/MiscTest.js @@ -0,0 +1,35 @@ +BinderTest.prototype.testExpandEntityTagWithName = function(){ + var c = this.compile('
'); + assertEquals( + '', + sortedHtml(c.node)); + assertEquals("Person", c.scope.$get("friend.$entity")); + assertEquals("friend", c.scope.$get("friend.$$anchor")); +}; + +BinderTest.prototype.XtestExpandSubmitButtonToAction = function(){ + var html = this.compileToHtml(''); + assertTrue(html, html.indexOf('ng-action="$save()"') > 0 ); + assertTrue(html, html.indexOf('ng-bind-attr="{"disabled":"{{$invalidWidgets}}"}"') > 0 ); +}; + +BinderTest.prototype.XtestReplaceFileUploadWithSwf = function(){ + expectAsserts(1); + var form = jQuery("body").append(''); + form.data('scope', new Scope()); + var factory = {}; + var binder = new Binder(form.get(0), factory, new MockLocation()); + factory.createController = function(node){ + assertEquals(node.attr('type'), 'file'); + return {updateModel:function(){}}; + }; + binder.compile(); + jQuery("#testTag").remove(); +}; + +BinderTest.prototype.testExpandEntityTagWithDefaults = function(){ + assertEquals( + '', + this.compileToHtml('