Message200994
Or if we really want to test these constants, we can use something like this:
if hasattr(resource, 'RLIMIT_NICE'):
self.assertIsInstance(resource.RLIMIT_NICE, int)
Or if we want to be so strict:
if hasattr(resource, 'RLIMIT_NICE'):
self.assertTrue(-20 <= resource.RLIMIT_NICE <= 19)
Reference:
http://man7.org/conf/lca2006/Linux_2.6_changes/rlimit_5.html
RLIMIT_NICE (2.6.12)
Process nice value has range -20 (high) to +19 (low); influences kernel scheduler. |
|
Date |
User |
Action |
Args |
2013-10-23 02:45:16 | vajrasky | set | recipients:
+ vajrasky, christian.heimes, mcepl, skrah |
2013-10-23 02:45:16 | vajrasky | set | messageid: <1382496316.16.0.435307341508.issue19353@psf.upfronthosting.co.za> |
2013-10-23 02:45:16 | vajrasky | link | issue19353 messages |
2013-10-23 02:45:15 | vajrasky | create | |
|