/**
* My xUnit Test
*/
component extends="testbox.system.BaseSpec"{
	
/*********************************** LIFE CYCLE Methods ***********************************/

	// executes before all test cases
	function beforeTests(){
	}

	// executes after all test cases
	function afterTests(){
	}

	// executes before every test case
	function setup( currentMethod ){
	}

	// executes after every test case
	function teardown( currentMethod ){
	}

/*********************************** TEST CASES BELOW ***********************************/
	
	// Remember that test cases MUST start or end with the keyword 'test'
	function testBasicClosure() test{
		include template="/examples/closures/basic_closure.cfm";
		expect(isClosure(myClosure)).toBeTrue();
	}

	function testAnonymousClosure() test{
		include template="/examples/closures/anonymous_closure.cfm";
		expect(newArray).toBe(["ONE","TWO","THREE"]);
	}

	function testClosureScopes() test{
		include template="/examples/closures/closure_scopes_example.cfm";
		expect(function(){outerClosure()}).toThrow();
		expect(function(){otherClosure()}).toThrow();
	}
	
}