buildtest.buildsystem.scriptbuilder
¶
Module Contents¶
Classes¶
The BuilderBase is an abstract class that implements common functions for |
- class buildtest.buildsystem.scriptbuilder.ScriptBuilder(name, recipe, buildspec, executor, buildexecutor, testdir)¶
Bases:
buildtest.buildsystem.base.BuilderBase
The BuilderBase is an abstract class that implements common functions for any kind of builder.
- type = script¶
- generate_script(self)¶
This method builds the testscript content based on the builder type. For ScriptBuilder we need to add the shebang, environment variables and the run section. If shell is python we write a python script and return immediately. The variables, environment section are not applicable for python scripts
- Returns
return content of test script
- Return type
list
- write_python_script(self)¶
This method is used for writing python script when
shell: python
is set. The content fromrun
section is added into a python script. The file is written to run directory and we simply invoke python script by runningpython script.py