def test_runimage_and_quit():
    from targetrsqueak import active_context, execute_context
    space, interp = runningExitImage(cached=False)
    frame = active_context(space)
    try:
        execute_context(interp, frame)
    except error.Exit, e:
        assert e.msg == "Quit-Primitive called"
def test_runimage_and_quit():
    from targetrsqueak import active_context, execute_context
    space, interp = runningExitImage(cached=False)
    frame = active_context(space)
    try:
        execute_context(interp, frame)
    except error.Exit, e:
        assert e.msg == "Quit-Primitive called"
Example #3
0
def run_image(imagename):
    from targetrsqueak import prebuilt_space as space, \
            compile_code, create_context, execute_context, \
            active_context
    interp = load(image_path(imagename), space=space)
    context = active_context(space)
    def interp_run_image():
        w_result = execute_context(interp, context)
        return 0
    return interp_run_image
Example #4
0
def run_image(imagename):
    from targetrsqueak import prebuilt_space as space, \
            compile_code, create_context, execute_context, \
            active_context
    interp = load(image_path(imagename), space=space)
    context = active_context(space)

    def interp_run_image():
        w_result = execute_context(interp, context)
        return 0

    return interp_run_image