瀏覽代碼

Stress tests: adds logs and raising tasks

Ask Solem 11 年之前
父節點
當前提交
54272aeba0
共有 1 個文件被更改,包括 10 次插入0 次删除
  1. 10 0
      funtests/stress/stress/app.py

+ 10 - 0
funtests/stress/stress/app.py

@@ -124,6 +124,16 @@ def segfault():
     assert False, 'should not get here'
 
 
+@app.task
+def raising(exc=KeyError()):
+    raise exc
+
+
+@app.task
+def logs(msg):
+    print(msg)
+
+
 def marker(s, sep='-'):
     print('{0}{1}'.format(sep, s))
     while True: