Skip to content

Latest commit

 

History

History
20 lines (14 loc) · 729 Bytes

life-cycle_events.md

File metadata and controls

20 lines (14 loc) · 729 Bytes

Life-Cycle Events

ColdBox testing leverages TestBox's testing life-cycle events (http://testbox.ortusbooks.com/content/life-cycle_methods/index.html) in order to prepare the virtual ColdBox application, request context and then destroy it. For performance, a virtual application is loaded for all test cases contained within a test bundle CFC via the beforeAll() and destroyed under afterAll().

function beforeAll(){
	super.beforeAll();
	// do your own stuff here
}

function afterAll(){
	// do your own stuff here
	super.afterAll();
}

Important If you override any of these methods and do not funnel the super call, then you might get cached or unexpected results.