This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

作者 vajrasky
收信人 christian.heimes, mcepl, skrah, vajrasky
日期 2013-10-23.02:45:15
SpamBayes Score -1.0
Marked as misclassified
Message-id <1382496316.16.0.435307341508.issue19353@psf.upfronthosting.co.za>
In-reply-to
内容
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.
历史
日期 用户 动作 参数
2013-10-23 02:45:16vajrasky修改recipients: + vajrasky, christian.heimes, mcepl, skrah
2013-10-23 02:45:16vajrasky修改messageid: <1382496316.16.0.435307341508.issue19353@psf.upfronthosting.co.za>
2013-10-23 02:45:16vajrasky链接issue19353 messages
2013-10-23 02:45:15vajrasky创建