def test(waittime): time.sleep(waittime) cs = CallStack(gkeyword) cache(gkeyword, kwargs={ 'x': 1, 'y': 2, 'z': 3 }, call_stack=cs, callback=callback) cs.save() os._exit(0)
def test(waittime): time.sleep(waittime) cs = CallStack(gkeyword) val = cache(gkeyword, kwargs={ 'x': 1, 'y': 2, 'z': 3 }, call_stack=cs, callback=callback) cs.save() os._exit(0)
def patch_with(*args, **kwargs): if side_effect != UNDEFINED: return execute_side_effect(side_effect, args, kwargs) if rvalue != UNDEFINED: return rvalue return cache( method_to_patch, args=args, kwargs=kwargs, ignore=ignore, call_stack=context.stack, callback=callback, subsequent_rvalue=subsequent_rvalue, )
def test(fh): result = cache( mixed, args=(1,2), kwargs={'z': 3 } ) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(fh): result = cache( keyword, kwargs={ 'x': 1, 'y': 2, 'z': 3 } ) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(fh): result = cache( positional, args=(1,2,3) ) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(fh): result = cache(mixed, args=(1, 2), kwargs={'z': 3}) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(fh): result = cache(keyword, kwargs={'x': 1, 'y': 2, 'z': 3}) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(fh): result = cache(positional, args=(1, 2, 3)) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(fh): result = cache(keyword, kwargs={"x": 1, "y": 2, "z": 3}) fh.write(str(result == 6)) fh.close() os._exit(0)
def test(waittime): time.sleep(waittime) cs = CallStack(gkeyword) val = cache(gkeyword, kwargs={"x": 1, "y": 2, "z": 3}, call_stack=cs, callback=callback) cs.save() os._exit(0)