diff options
| author | Misko Hevery | 2010-01-28 22:10:49 -0800 |
|---|---|---|
| committer | Misko Hevery | 2010-01-28 22:11:01 -0800 |
| commit | a9c182764b5feeb2466c4bb32f7572762f7fab6d (patch) | |
| tree | 48105ad598ca6779e3308b06b12576a366e9be71 /test/WidgetsTest.js | |
| parent | dd9d8bf030688f589af6d47064a0d0eafea41bfa (diff) | |
| download | angular.js-a9c182764b5feeb2466c4bb32f7572762f7fab6d.tar.bz2 | |
added formatters
Diffstat (limited to 'test/WidgetsTest.js')
| -rw-r--r-- | test/WidgetsTest.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/WidgetsTest.js b/test/WidgetsTest.js index c0a2d082..4e3852a5 100644 --- a/test/WidgetsTest.js +++ b/test/WidgetsTest.js @@ -3,7 +3,7 @@ WidgetTest = TestCase('WidgetTest'); WidgetTest.prototype.testRequired = function () { var view = $('<input name="a" ng-required>'); var scope = new Scope({$invalidWidgets:[]}); - var cntl = new TextController(view[0], 'a'); + var cntl = new TextController(view[0], 'a', angularFormatter.noop); cntl.updateView(scope); assertTrue(view.hasClass('ng-validation-error')); assertEquals("Required Value", view.attr('ng-error')); @@ -16,7 +16,7 @@ WidgetTest.prototype.testRequired = function () { WidgetTest.prototype.testValidator = function () { var view = $('<input name="a" ng-validate="testValidator:\'ABC\'">'); var scope = new Scope({$invalidWidgets:[]}); - var cntl = new TextController(view[0], 'a'); + var cntl = new TextController(view[0], 'a', angularFormatter.noop); angular.validator.testValidator = function(value, expect){ return value == expect ? null : "Error text"; }; @@ -44,7 +44,7 @@ WidgetTest.prototype.testValidator = function () { WidgetTest.prototype.testRequiredValidator = function () { var view = $('<input name="a" ng-required ng-validate="testValidator:\'ABC\'">'); var scope = new Scope({$invalidWidgets:[]}); - var cntl = new TextController(view[0], 'a'); + var cntl = new TextController(view[0], 'a', angularFormatter.noop); angular.validator.testValidator = function(value, expect){ return value == expect ? null : "Error text"; }; |
