# Path: zaifbot/config.py
# def get_keys():
#     if env.get('ZAIFBOT_KEY') and env.get('ZAIFBOT_SECRET'):
#         return env['ZAIFBOT_KEY'], env['ZAIFBOT_SECRET']
# 
#     home = os.path.expanduser('~')
#     config_file = os.path.join(home, '.zaifbot')
#     if os.path.isfile(config_file):
#         config = configparser.ConfigParser()
#         config.read(config_file)
#         return config['api_keys']['key'], config['api_keys']['secret']
# 
#     raise ZaifBotError('api keys are not set')
# 
# def set_keys(key, secret):
#     env['ZAIFBOT_KEY'] = key
#     env['ZAIFBOT_SECRET'] = secret


import unittest
from os import environ as env
from zaifbot.config import get_keys, set_keys


class TestConfig(unittest.TestCase):
    def setUp(self):
        self._key = 'key'
        self._secret = 'secret'

    def test_set_keys(self):

# Path: zaifbot/config.py
# def get_keys():
#     if env.get('ZAIFBOT_KEY') and env.get('ZAIFBOT_SECRET'):
#         return env['ZAIFBOT_KEY'], env['ZAIFBOT_SECRET']
# 
#     home = os.path.expanduser('~')
#     config_file = os.path.join(home, '.zaifbot')
#     if os.path.isfile(config_file):
#         config = configparser.ConfigParser()
#         config.read(config_file)
#         return config['api_keys']['key'], config['api_keys']['secret']
# 
#     raise ZaifBotError('api keys are not set')
# 
# def set_keys(key, secret):
#     env['ZAIFBOT_KEY'] = key
#     env['ZAIFBOT_SECRET'] = secret


# Path: tests/test_config.py
import unittest
from os import environ as env
from zaifbot.config import get_keys, set_keys



class TestConfig(unittest.TestCase):
    def setUp(self):
        self._key = 'key'
        self._secret = 'secret'

    def test_set_keys(self):

        set_keys(self._key, self._secret)