Tests for after block

This commit is contained in:
2016-04-01 01:32:09 +05:30
parent 241e76e9d1
commit b88e355241
2 changed files with 14 additions and 1 deletions
+8 -1
View File
@@ -1,4 +1,4 @@
/* globals describe, it, before */ /* globals describe, it, before, after */
var messageLog = []; var messageLog = [];
var pr = function( msg ){ var pr = function( msg ){
@@ -42,11 +42,18 @@ var it2 = asyncFn({
error: null, error: null,
}); });
var afterFn = asyncFn({
msg: 'After_block',
delay: 60,
error: null,
});
describe( 'describe', function(){ describe( 'describe', function(){
before( beforeFn ); before( beforeFn );
it( 'it1', it1 ); it( 'it1', it1 );
it( 'it2', it2 ); it( 'it2', it2 );
after( afterFn );
}); });
+6
View File
@@ -46,6 +46,12 @@ describe( 'Simple before block + it s ', function(){
assert( itBlk.fn ); assert( itBlk.fn );
}); });
}); });
it( 'should parse after blocks', function(){
assert( firsDescribeBlock.afterFn );
});
}); });
}); });
}); });