test_env can capture output of __init__ function