Commit b9b2048c authored by Sebastien Robin's avatar Sebastien Robin

testnode: avoid to rebuild testnode dependencies (firefox) all the time (fix tests)

parent 85d5fd91
......@@ -720,9 +720,11 @@ shared = true
# TestNode
test_node = self.getTestNode()
# Modify class UnitTestRunner(or more after) method
def patch_prepareSlapOS(*args, **kw):
return {'status_code':0}
original_prepareSlapOS = RunnerClass._prepareSlapOS
original_runTestSuite = RunnerClass.runTestSuite
RunnerClass._prepareSlapOS = doNothing
RunnerClass._prepareSlapOS = patch_prepareSlapOS
RunnerClass.runTestSuite = patch_runTestSuite
SlapOSControler.initializeSlapOSControler = doNothing
# Inside test_node a runner is created using new UnitTestRunner methods
......@@ -886,7 +888,9 @@ shared = true
else:
RunnerClass.runTestSuite = doNothing
RunnerClass._prepareSlapOS = doNothing
def patch_prepareSlapOS(*args, **kw):
return {'status_code':0}
RunnerClass._prepareSlapOS = patch_prepareSlapOS
SlapOSControler.initializeSlapOSControler = doNothing
test_node.run()
self.assertEquals(counter, 3)
......
......@@ -302,8 +302,8 @@ shared = true
runner = runner_class(self)
logger.info("Type of current test is %s", my_test_type)
# master testnode gets test_suites, slaves get nothing
testnode_software_status_dict = runner.prepareSlapOSForTestNode(test_node_slapos)
if not(testnode_software_successfully_built):
testnode_software_status_dict = runner.prepareSlapOSForTestNode(test_node_slapos)
if testnode_software_status_dict['status_code'] == 0:
testnode_software_successfully_built = True
logger.info("Will now skip build of testnode software")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment