fix: ensure variables

This commit is contained in:
debugtalk
2020-06-07 14:50:07 +08:00
parent d1f9b10274
commit ddf5c331cc
5 changed files with 78 additions and 25 deletions

View File

@@ -7,7 +7,7 @@ from httprunner import HttpRunner, Config, Step, RunRequest, RunTestCase
class TestCaseRequestWithFunctions(HttpRunner):
config = (
Config("request with functions")
.variables(**{"foo1": "session_bar1", "var1": "testsuite_val1"})
.variables(**{"var1": "testsuite_val1", "foo1": "session_bar1"})
.base_url("https://postman-echo.com")
.verify(False)
.export(*["session_foo2"])

View File

@@ -16,7 +16,7 @@ from examples.postman_echo.request_methods.request_with_functions_test import (
class TestCaseRequestWithTestcaseReference(HttpRunner):
config = (
Config("request with referenced testcase")
.variables(**{"foo1": "session_bar1", "var2": "testsuite_val2"})
.variables(**{"var2": "testsuite_val2", "foo1": "session_bar1"})
.base_url("https://postman-echo.com")
.verify(False)
)