conservancy_beancount/tests/conftest.py
Brett Smith 8d3816a8fd config: Add Config.rt_credentials method.
This loads settings from the same environment variables and ~/.rtrc
file as the rt CLI.

Note that it does *not* support RTCONFIG and the config file
searching, because right now that seems like more work for more
trouble to me.
2020-03-23 15:19:15 -04:00

14 lines
380 B
Python

import os
import pytest
from . import testutil
@pytest.fixture(scope='session', autouse=True)
def clean_environment():
os.environ.pop('CONSERVANCY_REPOSITORY', None)
os.environ.pop('RTAUTH', None)
os.environ.pop('RTPASSWD', None)
os.environ.pop('RTSERVER', None)
os.environ.pop('RTUSER', None)
os.environ['HOME'] = str(testutil.test_path('userconfig'))