aboutsummaryrefslogtreecommitdiffstats
path: root/docs/spec/ngdocSpec.js
diff options
context:
space:
mode:
authorMisko Hevery2012-02-22 12:59:23 -0800
committerMisko Hevery2012-02-22 12:59:23 -0800
commitc27a56f4da9bf89e471ac6597c135e2f19814f17 (patch)
tree195faba53e34785e05d9685765880956ed9464f4 /docs/spec/ngdocSpec.js
parentfbcb7fdd141c277d326dc3ed34545210c4d5628f (diff)
downloadangular.js-c27a56f4da9bf89e471ac6597c135e2f19814f17.tar.bz2
docs(scope): show which directives create scopes
Diffstat (limited to 'docs/spec/ngdocSpec.js')
-rw-r--r--docs/spec/ngdocSpec.js20
1 files changed, 20 insertions, 0 deletions
diff --git a/docs/spec/ngdocSpec.js b/docs/spec/ngdocSpec.js
index 8082e4b1..4b809479 100644
--- a/docs/spec/ngdocSpec.js
+++ b/docs/spec/ngdocSpec.js
@@ -349,6 +349,26 @@ describe('ngdoc', function() {
});
});
+ describe('@scope', function() {
+ it('should state the new scope will be created', function() {
+ var doc = new Doc('@name a\n@scope');
+ doc.ngdoc = 'directive';
+ doc.parse();
+ expect(doc.scope).toEqual('');
+ expect(doc.html()).toContain('This directive creates new scope.');
+ });
+ });
+
+ describe('@priority', function() {
+ it('should state the priority', function() {
+ var doc = new Doc('@name a\n@priority 123');
+ doc.ngdoc = 'directive';
+ doc.parse();
+ expect(doc.priority).toEqual('123');
+ expect(doc.html()).toContain('This directive executes at priority level 123.');
+ });
+ });
+
describe('@property', function() {
it('should parse @property tags into array', function() {
var doc = new Doc("@name a\n@property {type} name1 desc\n@property {type} name2 desc");