Dalimonster
17 years agoOccasional Contributor
Teardown script is not running at all

I have been trying to figure out how to get my teardown script to run at all.
I was writing a teardown script that would execute a testcase in the testsuite. When this didn't work I just added a log.info line to the teardown script. When I execute the project, I don't see the line that I'm printing to the log anywhere in the log. The teardown test case is also not being executed.
Can someone please help me?
This my original code:
import com.eviware.soapui.SoapUI;
import com.eviware.soapui.model.testsuite.*;
import com.varolii.DataObjects.*;
import java.util.regex.*
import com.eviware.soapui.support.types.*;
def testCase = testSuite.testCases["Tear Down Script"]
def properties = new com.eviware.soapui.support.types.StringToObjectMap()
def async = false
log.info("Inside Teardown script");
testCase.run( properties, async )
I changed the last line to:
testRunner.testSuite.testCases["Tear Down Script"].run(testRunner, context);
and it still doesn't run.
Can someone please help me with this problem?