コード例 #1
0
def pytest_configure(config):
    if config.getvalue('random'):
        from rpython.rlib import jit
        jit.isconstant = replace(jit.isconstant)
        jit.isvirtual = replace(jit.isvirtual)
        # XXX: Being able to patch we_are_jitted would be nice as well,
        # but too much code depends on it behaving deterministically

    from pycket.env import w_global_config

    config.byte_option = False
    config.new_pycket = False
    config.load_expander = False

    if config.getvalue('--new'):
        print("\nTesting with NEW Pycket... ")
        config.new_pycket = True
        if config.getvalue('--use-expander'):
            print("using the expander linklet...\n")
            w_global_config.set_config_val('expander_loaded', 1)
            config.load_expander = True
        else:
            print("WITHOUT using the expander linklet...\n")
    else:
        print("\nTesting with OLD Pycket... ")
        w_global_config.set_linklet_mode_off()
コード例 #2
0
ファイル: conftest.py プロジェクト: yws/pycket-1
def pytest_configure(config):
    if config.getvalue('random'):
        from rpython.rlib import jit
        jit.isconstant = replace(jit.isconstant)
        jit.isvirtual = replace(jit.isvirtual)
        # XXX: Being able to patch we_are_jitted would be nice as well,
        # but too much code depends on it behaving deterministically

    byte_flag = config.getvalue('bytecode')

    if byte_flag == "":
        print "We have regular pycket expansion"
        config.byte_option = False
    elif byte_flag == "go":
        print "We have bytecode expansion"
        config.byte_option = True
コード例 #3
0
ファイル: conftest.py プロジェクト: rjnw/pycket
def pytest_configure(config):
    byte_flag = config.getvalue('bytecode')

    if byte_flag == "":
        print "We have regular pycket expansion"
        config.byte_option = False
    elif byte_flag == "go":
        print "We have bytecode expansion"
        config.byte_option = True
コード例 #4
0
def pytest_configure(config):
    byte_flag = config.getvalue('bytecode')

    if byte_flag == "":
        print "We have regular pycket expansion"
        config.byte_option = False
    elif byte_flag == "go":
        print "We have bytecode expansion"
        config.byte_option = True
コード例 #5
0
ファイル: conftest.py プロジェクト: cderici/pycket
def pytest_configure(config):
    byte_flag = config.getvalue('bytecode')

    if byte_flag == "":
        print "We have regular pycket expansion"
        config.byte_option = False
    elif byte_flag == "nonRecursive":
        print "We have NON-recursive bytecode expansion"
        config.byte_option = "non-recursive"
    elif byte_flag == "recursive":
        print "We have recursive bytecode expansion"
        config.byte_option = "recursive"