<caseResult _class='hudson.tasks.junit.CaseResult'><age>0</age><className>tests.wurstscript.tests.OptimizerTests</className><duration>0.184</duration><failedSince>0</failedSince><name>test_ConstFolding</name><skipped>false</skipped><status>PASSED</status><stderr></stderr><stdout>// this script was compiled with wurst 1.8.0.0-jenkins-Wurst-1095
globals
integer tempReturn_integer=0
endglobals
native testSuccess takes nothing returns nothing
function initGlobals takes nothing returns nothing
endfunction

function cyc_foo takes integer funcChoice, integer x returns nothing
	if funcChoice == 0 then
		if x &gt; 1000 then
			call cyc_foo(3, x)
			set tempReturn_integer = tempReturn_integer
			return
		endif
		if x &gt; 100 then
			call cyc_foo(1, x)
			set tempReturn_integer = tempReturn_integer
			return
		endif
		if x &gt; 10 then
			call cyc_foo(2, x)
			set tempReturn_integer = tempReturn_integer
			return
		endif
		set tempReturn_integer = x
		return
	elseif funcChoice == 1 then
		call cyc_foo(0, x / 100)
		set tempReturn_integer = tempReturn_integer
		return
	elseif funcChoice == 2 then
		call cyc_foo(0, x / 10)
		set tempReturn_integer = tempReturn_integer
		return
	elseif funcChoice == 3 then
		call cyc_foo(0, x / 1000)
		set tempReturn_integer = tempReturn_integer
		return
	endif
endfunction

function init_Test takes nothing returns nothing
	call cyc_foo(0, 7531)
	if tempReturn_integer == 7 then
		call testSuccess()
	endif
endfunction

function main takes nothing returns nothing
	call initGlobals()
	call init_Test()
endfunction

function config takes nothing returns nothing
endfunction


</stdout></caseResult>