mirror of
https://github.com/httprunner/httprunner.py.git
synced 2026-05-12 02:19:49 +08:00
init: move from httprunner/httprunner
This commit is contained in:
42
examples/postman_echo/debugtalk.py
Normal file
42
examples/postman_echo/debugtalk.py
Normal file
@@ -0,0 +1,42 @@
|
||||
from httprunner import __version__
|
||||
|
||||
|
||||
def get_httprunner_version():
|
||||
return __version__
|
||||
|
||||
|
||||
def sum_two(m, n):
|
||||
return m + n
|
||||
|
||||
|
||||
def get_testcase_config_variables():
|
||||
return {"foo1": "testcase_config_bar1", "foo2": "testcase_config_bar2"}
|
||||
|
||||
|
||||
def get_testsuite_config_variables():
|
||||
return {"foo1": "testsuite_config_bar1", "foo2": "testsuite_config_bar2"}
|
||||
|
||||
|
||||
def get_app_version():
|
||||
return [3.1, 3.0]
|
||||
|
||||
|
||||
def calculate_two_nums(a, b=1):
|
||||
return [a + b, b - a]
|
||||
|
||||
|
||||
def fake_rand_count():
|
||||
"""
|
||||
return 1 at first call
|
||||
return 2 at second call
|
||||
"""
|
||||
l = []
|
||||
|
||||
def func():
|
||||
l.append(1)
|
||||
return len(l)
|
||||
|
||||
return func
|
||||
|
||||
|
||||
fake_randnum = fake_rand_count()
|
||||
Reference in New Issue
Block a user