init
	Test.init( ref args )
	Test.add_func( "/FunctionalTests/Genie/Objects/Constructors/Multiline/01", multiline1 )
	Test.add_func( "/FunctionalTests/Genie/Objects/Constructors/Multiline/02", multiline2 )
	Test.add_func( "/FunctionalTests/Genie/Objects/Constructors/Multiline/03", multiline3 )
	Test.add_func( "/FunctionalTests/Genie/Objects/Constructors/Multiline/04", multiline4 )
	Test.add_func( "/FunctionalTests/Genie/Objects/Constructors/Multiline/05", multiline5 )
	Test.run()

// No whitespace between parens and arguments
def multiline1()
	var test = new multiple_parameters(1,
		2,
		3)
	assert( test.result == 6 )
	return

// Whitespace between opening parens and first argument
def multiline2()
	var test = new multiple_parameters(
		1,
		2,
		3)
	assert( test.result == 6 )
	return

// Whitespace between closing parens and last argument
def multiline3()
	var test = new multiple_parameters(1,
		2,
		3 )
	assert( test.result == 6 )
	return

// Multiline arguments with exception
def multiline4()
	try
		var test = new multiple_parameters_with_raises_error( 1,
			2,
			3
			)
		assert( test.result == 6 )
	except
		assert_not_reached()
	return

// Multiline arguments and multiline parameters in constructor with exception
def multiline5()
	try
		var test = new multiline_constructor_with_raises_error( 1,
			2,
			3
			)
		assert( test.result == 6 )
	except
		assert_not_reached()
	return

class multiline_constructor_with_raises_error
	result:int = 0
	construct ( a:int, 
				b:int, 
				c:int ) raises TestError
		if a == 0
			raise new TestError.DUMMY( "First parameter is zero" )
		result = a + b + c

// Classes used in tests 01 to 04
class multiple_parameters
	result:int = 0
	construct ( a:int, b:int, c:int )
		result = a + b + c

class multiple_parameters_with_raises_error
	result:int = 0
	construct ( a:int, b:int, c:int ) raises TestError
		if a == 0
			raise new TestError.DUMMY( "First parameter is zero" )
		result = a + b + c

// Exception used in tests
exception TestError
	DUMMY
