Exemple #1
0
def test_multiple_runs_of_setup_function():
    '''make sure our fixes support multiple runs '''
    from esky.bdist_esky import Executable
    setup, options, new_script = esky_setup('Simple Working', WORKING_SCRIPT)
    new_script2 = make_new_script_name('test_multiple_working.py')
    insert_code(new_script2,'import sys')
    options2 = copy.deepcopy(options)
    options2['scripts'] = [new_script2]
    options2['version'] = '0.2'
    esky_zip_name = get_zip_name(options2)

    # Now test that freeze future works as well
    cleanup_dirs()

    setup(**options)
    clean_exit, stderr = run_script(new_script, freezer='esky')
    assert clean_exit

    # only works if we cleanup dirs.. same as original esky
    cleanup_dirs()

    setup(**options2)
    if os.name == 'nt':
        platform = get_platform()
        esky_zip_name = 'Simple Working-0.2.%s.zip' % platform
    clean_exit, stderr = run_script(new_script2, freezer='esky', zip_name=esky_zip_name)
    assert clean_exit
Exemple #2
0
def teardown_function(func):
    cleanup_dirs()
Exemple #3
0
def teardown_function(func):
    cleanup_dirs()
Exemple #4
0
def teardown_module():
    cleanup_dirs()
Exemple #5
0
def setup_function(func):
    cleanup_dirs()
Exemple #6
0
def teardown_module():
    # Unlike cxfreeze somehow if i cleanup after each build it f***s up...,
    cleanup_dirs()