diff options
| author | Igor Minar | 2010-11-02 16:23:12 -0700 |
|---|---|---|
| committer | Igor Minar | 2010-11-03 09:44:54 -0700 |
| commit | 0bd4a473a717d5ed9b9c07fbdbc5c336beeef4e5 (patch) | |
| tree | 991b68c0f04ac39a044f67cb36a14d60681724ca /test/scenario/dslSpec.js | |
| parent | dcf76e681624dca350d00a4a2e5f5d63deffcb17 (diff) | |
| download | angular.js-0bd4a473a717d5ed9b9c07fbdbc5c336beeef4e5.tar.bz2 | |
adding regular expressions support for binding() DSL
Diffstat (limited to 'test/scenario/dslSpec.js')
| -rw-r--r-- | test/scenario/dslSpec.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/scenario/dslSpec.js b/test/scenario/dslSpec.js index 9f7bf085..fd22303e 100644 --- a/test/scenario/dslSpec.js +++ b/test/scenario/dslSpec.js @@ -370,6 +370,12 @@ describe("angular.scenario.dsl", function() { expect($root.futureResult).toEqual('some value'); }); + it('should select binding by regexp', function() { + doc.append('<span class="ng-binding" ng:bind="foo.bar">some value</span>'); + $root.dsl.binding(/^foo\..+/); + expect($root.futureResult).toEqual('some value'); + }); + it('should select binding in template by name', function() { doc.append('<pre class="ng-binding" ng:bind-template="foo {{bar}} baz">foo some baz</pre>'); $root.dsl.binding('bar'); |
