@@ -610,17 +610,32 @@ describe('Gren', () => {
610610 } ) ;
611611 } ) ;
612612
613- it ( '_getReleaseBlocks' , done => {
614- gren . options . tags = [ '0.12.0' , '0.11.0' ] ;
615- gren . _getReleaseBlocks ( )
616- . then ( releaseBlocks => {
617- assert . isArray ( releaseBlocks , 'The releaseBlocks is an Array' ) ;
618- releaseBlocks . forEach ( block => {
619- assert . hasAllKeys ( block , [ 'id' , 'release' , 'name' , 'published_at' , 'body' ] ) ;
620- } ) ;
621- done ( ) ;
622- } )
623- . catch ( err => done ( err ) ) ;
624- } ) . timeout ( 10000 ) ;
613+ describe ( '_getReleaseBlocks' , ( ) => {
614+ it ( 'more than one tag' , done => {
615+ gren . options . tags = [ '0.12.0' , '0.11.0' ] ;
616+ gren . _getReleaseBlocks ( )
617+ . then ( releaseBlocks => {
618+ assert . isArray ( releaseBlocks , 'The releaseBlocks is an Array' ) ;
619+ releaseBlocks . forEach ( block => {
620+ assert . hasAllKeys ( block , [ 'id' , 'release' , 'name' , 'published_at' , 'body' ] ) ;
621+ } ) ;
622+ done ( ) ;
623+ } )
624+ . catch ( err => done ( err ) ) ;
625+ } ) . timeout ( 10000 ) ;
626+
627+ it ( 'just one tag' , done => {
628+ gren . options . tags = [ '0.11.0' ] ;
629+ gren . _getReleaseBlocks ( )
630+ . then ( releaseBlocks => {
631+ assert . isArray ( releaseBlocks , 'The releaseBlocks is an Array' ) ;
632+ releaseBlocks . forEach ( block => {
633+ assert . hasAllKeys ( block , [ 'id' , 'release' , 'name' , 'published_at' , 'body' ] ) ;
634+ } ) ;
635+ done ( ) ;
636+ } )
637+ . catch ( err => done ( err ) ) ;
638+ } ) . timeout ( 10000 ) ;
639+ } ) ;
625640 } ) ;
626641} ) ;
0 commit comments