Esempio n. 1
0
def teardown_tmp_repo():
    """
    Remove the test repo
    """

    log.info(__name__ + ':: Tearing down test repo.')

    chdir(config['deploy.test_repo'])
    rmtree(config['deploy.test_repo'])
Esempio n. 2
0
def init_tmp_repo():
    """
    Create a test repo, change to directory
    """

    log.info(__name__ + ':: Creating test repo.')

    if exists(config['deploy.test_repo']):
        rmtree(config['deploy.test_repo'])

    mkdir(config['deploy.test_repo'])
    Repo.init(config['deploy.test_repo'])
    chdir(config['deploy.test_repo'])