Line # | Kind | Name | Docs |
---|---|---|---|
39 | Function | env_var_expand | Expand the given environment variable content. If it contains |
77 | Function | env_var_explode_list | Explode a list of values stored in an environment variable as a |
106 | Function | un_camelify | Convert CamelCase styled strings to lower_cased style. |
129 | Function | is_hildon_desktop_running | Undocumented |
155 | Function | get_distro | Undocumented |
179 | Function | get_os_name | Undocumented |
187 | Function | pkg_resources_copy_dir | Copy a directory recursively using pkg_resources. |
215 | Function | run_functional_tests_check | Check whether functional tests should be run or not. This is done by |
241 | Function | chainDeferredIgnoringResult | Undocumented |
252 | Function | callAfterDeferredCalled | Undocumented |
Expand the given environment variable content. If it contains other references to environment variables, they are expanded too.
Supported platforms are win32 and linux.
Example of use:>>> env_var_expand('$HOME') >>> '/home/phil'
Parameters | var_name | environment variable (type: string ) |
Returns | (type: string ) | |
Raises | ValueError | if current system's platform is not windows or linux |
Explode a list of values stored in an environment variable as a single string. On win32 the item separator is ';' and on other platforms it is ':'.
Example of use:>>> env_var_explode_list('$PATH') >>> ['/usr/bin','/bin']
Parameters | var_name | environment variable (type: string ) |
default | value to use if environment variable not found (type: string ) | |
Returns | (type: list of strings ) |
Parameters | camel_string | CamelStyled string to convert (type: string ) |
Returns | (type: string ) |
Check whether functional tests should be run or not. This is done by
checking whether the FUNCTIONAL_TESTS_STR
environment variable
is set to 'True'. If it is not explictly set to True, this method raises a
twisted.trial.unittest.SkipTest
(saying that the functional
test is not run).
from elisa.core.utils.misc import run_functional_tests_check [...] class MyFunctionalTestCase(TestCase): def setUp(self): run_functional_tests_check() ...