2
mocha before ()의 비동기 함수는 it () 사양 전에 항상 완료됩니까?
before()데이터베이스 정리를위한 콜백 함수가 있습니다. 시작 before()하기 전에 모든 것이 완료 되도록 보장 it()됩니까? before(function(){ db.collection('user').remove({}, function(res){}); // is it guaranteed to finish before it()? }); it('test spec', function(done){ // do the test }); after(function(){ });