From 2da07127e45312ce22d894aa771b8797e9a301a1 Mon Sep 17 00:00:00 2001 From: Vojta Jina Date: Tue, 24 May 2011 00:49:33 +0200 Subject: Add doc:tutorial-instructions widget --- docs/spec/ngdocSpec.js | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'docs/spec') diff --git a/docs/spec/ngdocSpec.js b/docs/spec/ngdocSpec.js index 7ad364c0..e4e21e25 100644 --- a/docs/spec/ngdocSpec.js +++ b/docs/spec/ngdocSpec.js @@ -165,11 +165,38 @@ describe('ngdoc', function(){ '

asdf x

'); }); + it('should ignore doc widgets', function() { + expect(new Doc().markdown('textdo not touch')). + toEqual('

text

do not touch'); + + expect(new Doc().markdown('textdo not touch')). + toEqual('

text

do not touch'); + }); + + it('should ignore doc widgets with params', function() { + expect(new Doc().markdown('textdo not touch')). + toEqual('

text

do not touch'); + }); + it('should replace text between two
 tags', function() {
       expect(new Doc().markdown('
x
# One
b
')). toMatch('

One

\n' + + '' + + '\ngit bla bla\n\n' + + '')).toEqual( + + '

before

\n' + + '\n' + + 'git bla bla\n' + + '\n' + + ''); + }); + it('should unindent text before processing based on the second line', function() { expect(new Doc().markdown('first line\n' + ' second line\n\n' + -- cgit v1.2.3