def test_tolerates_attribs(self):
"""
Classes are allowed to have plain attr.ibs for e.g.
__attrs_post_init__.
"""
@environ.config
class Cfg(object):
e = environ.var()
x = attr.ib(default=42)
cfg = environ.to_config(Cfg, environ={
"APP_E": "e",
})
assert Cfg("e", 42) == cfg
评论列表
文章目录