예제 #1
0
파일: test_system.py 프로젝트: haje01/wzdat
def _reset_data():
    print 'reset data'
    from wzdat.util import gen_dummydata, get_var_dir
    cfg = make_config()
    ddir = cfg['data_dir']

    # remove previous dummy data
    if os.path.isdir(ddir):
        print 'remove datadir'
        shutil.rmtree(ddir)

    # generate new dummy data
    gen_dummydata(ddir, 10, False)
    # make _var_ dir
    get_var_dir()
예제 #2
0
파일: conftest.py 프로젝트: haje01/wzdat
def fxlogs():
    from wzdat.util import gen_dummydata
    ddir = cfg['data_dir']
    # remove previous dummy data
    import shutil
    shutil.rmtree(ddir)

    # generate new dummy data
    gen_dummydata(ddir)
    from ws_mysol.myprj import log
    log.load_info()
    from ws_mysol.myprj import exlog
    exlog.load_info()
    from ws_mysol.myprj import dump
    dump.load_info()
    yield log, exlog, dump