refactor: move base_url to config env

This commit is contained in:
debugtalk
2022-05-24 22:23:02 +08:00
parent f141db43f0
commit 9f48fd1d60
20 changed files with 55 additions and 29 deletions

View File

@@ -0,0 +1,3 @@
base_url=https://postman-echo.com
USERNAME=debugtalk
PASSWORD=123456

View File

@@ -1,4 +1,3 @@
.env
reports/
*.so
.vscode/

View File

@@ -1,6 +1,6 @@
{
"project_name": "demo-with-go-plugin",
"project_path": "/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner/examples/demo-with-go-plugin",
"create_time": "2022-05-24T11:10:10.127839+08:00",
"create_time": "2022-05-24T22:21:23.330967+08:00",
"hrp_version": "v4.1.0-beta"
}

View File

@@ -5,7 +5,6 @@ config:
foo2: config_bar2
expect_foo1: config_bar1
expect_foo2: config_bar2
base_url: "https://postman-echo.com"
verify: False
export: ["foo3"]
@@ -18,7 +17,7 @@ teststeps:
sum_v: "${sum_two_int(1, 2)}"
request:
method: GET
url: /get
url: $base_url/get
params:
foo1: $foo1
foo2: $foo2
@@ -39,7 +38,7 @@ teststeps:
foo3: "bar32"
request:
method: POST
url: /post
url: $base_url/post
headers:
User-Agent: funplugin/${get_version()}
Content-Type: "text/plain"
@@ -53,7 +52,7 @@ teststeps:
foo2: bar23
request:
method: POST
url: /post
url: $base_url/post
headers:
User-Agent: funplugin/${get_version()}
Content-Type: "application/x-www-form-urlencoded"

View File

@@ -0,0 +1,3 @@
base_url=https://postman-echo.com
USERNAME=debugtalk
PASSWORD=123456

View File

@@ -1,4 +1,3 @@
.env
reports/
*.so
.vscode/

View File

@@ -1,6 +1,6 @@
{
"project_name": "demo-with-py-plugin",
"project_path": "/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner/examples/demo-with-py-plugin",
"create_time": "2022-05-24T11:10:15.544763+08:00",
"create_time": "2022-05-24T22:21:30.722372+08:00",
"hrp_version": "v4.1.0-beta"
}

View File

@@ -5,7 +5,6 @@ config:
foo2: config_bar2
expect_foo1: config_bar1
expect_foo2: config_bar2
base_url: "https://postman-echo.com"
verify: False
export: ["foo3"]
@@ -18,7 +17,7 @@ teststeps:
sum_v: "${sum_two_int(1, 2)}"
request:
method: GET
url: /get
url: $base_url/get
params:
foo1: $foo1
foo2: $foo2
@@ -39,7 +38,7 @@ teststeps:
foo3: "bar32"
request:
method: POST
url: /post
url: $base_url/post
headers:
User-Agent: funplugin/${get_version()}
Content-Type: "text/plain"
@@ -53,7 +52,7 @@ teststeps:
foo2: bar23
request:
method: POST
url: /post
url: $base_url/post
headers:
User-Agent: funplugin/${get_version()}
Content-Type: "application/x-www-form-urlencoded"

View File

@@ -0,0 +1,3 @@
base_url=https://postman-echo.com
USERNAME=debugtalk
PASSWORD=123456

View File

@@ -1,4 +1,3 @@
.env
reports/
*.so
.vscode/

View File

@@ -1,6 +1,6 @@
{
"project_name": "demo-without-plugin",
"project_path": "/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner/examples/demo-without-plugin",
"create_time": "2022-05-24T11:10:16.993462+08:00",
"create_time": "2022-05-24T22:21:31.676833+08:00",
"hrp_version": "v4.1.0-beta"
}