will print current working dir, then other_dir, then first dir again
* a wrapper around "df" to determine size and usage of file systems
-.. todo:: create unittest
+.. todo:: change get_filesystem_fill_states to not fork
.. codeauthor:: Christian Herdtweck, christian.herdtweck@intra2net.com
"""
class TestHelperTester(unittest.TestCase):
def assertNoWarn(self, func, *args, **kwargs):
- """ check that calling function raises no warning
+ """ check that calling function raises no warning
use warnings.catch_warnings instead of self.assertWarn
for compatibility with python 2
def assertWarn(self, warn_type, message, func, *args, **kwargs):
- """ check that calling function raises no warning
+ """ check that calling function raises no warning
use warnings.catch_warnings instead of self.assertWarn
for compatibility with python 2
def nonsense_function(self, sleep_time):
- """ function to run while checking disc fill state; just sleeps """
+ """ function to run while checking disc fill state; just sleeps
+
+ to make this test quicker could try to use profiling to count calls to
+ disc checker function and stop this after 2 or so
+ """
sleep(sleep_time)
def threading_profile_func(self, *args, **kwargs):
+ """ todo: set this as profiling function for checker thread, count
+ calls to disc checker function, trigger event or so """
print('profiling with args {0} and kwargs {1}'
.format([arg for arg in args if len(args) < 20], kwargs))