lib/assert.js
function( startFunc, forced ) {
		var self = this, i, mod;

		// Can only close an active module
		self.requireState( munit.ASSERT_STATE_ACTIVE, self.close );

		// Add fail marker if no tests were ran
		if ( self.count < 1 ) {
			self.fail( "[munit] No tests ran in this module" );
		}

		// Auto close out any spies
		self._spies.reverse().forEach(function( spy ) {
			spy.restore();
		});

		// Proxy teardown to pass start function and forced state
		self._teardown(function( e, teardownCallback ) {
			if ( e ) {
				self._fail( "[munit] failed to teardown '" + self.nsPath + "' module properly", teardownCallback );
			}

			self._close( startFunc || self.close, forced );
		});

		return self;
	}
function( startFunc, forced ) {
		var self = this, i, mod;

		// Can only close an active module
		self.requireState( munit.ASSERT_STATE_ACTIVE, self.close );

		// Add fail marker if no tests were ran
		if ( self.count < 1 ) {
			self.fail( "[munit] No tests ran in this module" );
		}

		// Auto close out any spies
		self._spies.reverse().forEach(function( spy ) {
			spy.restore();
		});

		// Proxy teardown to pass start function and forced state
		self._teardown(function( e, teardownCallback ) {
			if ( e ) {
				self._fail( "[munit] failed to teardown '" + self.nsPath + "' module properly", teardownCallback );
			}

			self._close( startFunc || self.close, forced );
		});

		return self;
	}
function ( startFunc , forced ) { var self = this , i , mod ; // Can only close an active module self . requireState ( munit . ASSERT_STATE_ACTIVE , self . close ) ; // Add fail marker if no tests were ran if ( self . count < 1 ) { self . fail ( "[munit] No tests ran in this module" ) ; } // Auto close out any spies self . _spies . reverse ( ) . forEach ( function ( spy ) { spy . restore ( ) ; } ) ; // Proxy teardown to pass start function and forced state self . _teardown ( function ( e , teardownCallback ) { if ( e ) { self . _fail ( "[munit] failed to teardown '" + self . nsPath + "' module properly" , teardownCallback ) ; } self . _close ( startFunc || self . close , forced ) ; } ) ; return self ; }
Forcing close of module
Forcing close of module