def getTestRunError(connection, sessionUrl): ''' This method gets the error that appeared during the last test run. If no error appeared (the test ran successfully), the return value will be 'None'. Args: - connection is the connection object that manages the HTTP data transfers between the client and the REST API - sessionUrl is the address of the session that should run the test. ''' activeTestUrl = "%s/ixload/test/activeTest" % (sessionUrl) testObj = connection.httpGet(activeTestUrl) return testObj.testRunError