mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-05 15:37:35 +08:00
feat: specify running cycles for load testing.
This commit is contained in:
+3
-3
@@ -29,8 +29,8 @@ Copyright 2021 debugtalk
|
|||||||
### SEE ALSO
|
### SEE ALSO
|
||||||
|
|
||||||
* [hrp boom](hrp_boom.md) - run load test with boomer
|
* [hrp boom](hrp_boom.md) - run load test with boomer
|
||||||
* [hrp har2case](hrp_har2case.md) - Convert HAR to json/yaml testcase files
|
* [hrp har2case](hrp_har2case.md) - convert HAR to json/yaml testcase files
|
||||||
* [hrp run](hrp_run.md) - run API test
|
* [hrp run](hrp_run.md) - run API test
|
||||||
* [hrp startproject](hrp_startproject.md) - Create a scaffold project
|
* [hrp startproject](hrp_startproject.md) - create a scaffold project
|
||||||
|
|
||||||
###### Auto generated by spf13/cobra on 8-Jan-2022
|
###### Auto generated by spf13/cobra on 12-Jan-2022
|
||||||
|
|||||||
@@ -38,4 +38,4 @@ hrp boom [flags]
|
|||||||
|
|
||||||
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
||||||
|
|
||||||
###### Auto generated by spf13/cobra on 8-Jan-2022
|
###### Auto generated by spf13/cobra on 12-Jan-2022
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
## hrp har2case
|
## hrp har2case
|
||||||
|
|
||||||
Convert HAR to json/yaml testcase files
|
convert HAR to json/yaml testcase files
|
||||||
|
|
||||||
### Synopsis
|
### Synopsis
|
||||||
|
|
||||||
Convert HAR to json/yaml testcase files
|
convert HAR to json/yaml testcase files
|
||||||
|
|
||||||
```
|
```
|
||||||
hrp har2case $har_path... [flags]
|
hrp har2case $har_path... [flags]
|
||||||
@@ -23,4 +23,4 @@ hrp har2case $har_path... [flags]
|
|||||||
|
|
||||||
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
||||||
|
|
||||||
###### Auto generated by spf13/cobra on 8-Jan-2022
|
###### Auto generated by spf13/cobra on 12-Jan-2022
|
||||||
|
|||||||
+1
-1
@@ -31,4 +31,4 @@ hrp run $path... [flags]
|
|||||||
|
|
||||||
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
||||||
|
|
||||||
###### Auto generated by spf13/cobra on 8-Jan-2022
|
###### Auto generated by spf13/cobra on 12-Jan-2022
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
## hrp startproject
|
## hrp startproject
|
||||||
|
|
||||||
Create a scaffold project
|
create a scaffold project
|
||||||
|
|
||||||
```
|
```
|
||||||
hrp startproject $project_name [flags]
|
hrp startproject $project_name [flags]
|
||||||
@@ -16,4 +16,4 @@ hrp startproject $project_name [flags]
|
|||||||
|
|
||||||
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
* [hrp](hrp.md) - One-stop solution for HTTP(S) testing.
|
||||||
|
|
||||||
###### Auto generated by spf13/cobra on 8-Jan-2022
|
###### Auto generated by spf13/cobra on 12-Jan-2022
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package boomer
|
package boomer
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"sync/atomic"
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
@@ -109,7 +110,7 @@ func TestLoopCount(t *testing.T) {
|
|||||||
ticker := time.NewTicker(4 * time.Second)
|
ticker := time.NewTicker(4 * time.Second)
|
||||||
defer ticker.Stop()
|
defer ticker.Stop()
|
||||||
<-ticker.C
|
<-ticker.C
|
||||||
if !assert.Equal(t, runner.loop.loopCount, runner.loop.finishedCount) {
|
if !assert.Equal(t, runner.loop.loopCount, atomic.LoadInt64(&runner.loop.finishedCount)) {
|
||||||
t.Fail()
|
t.Fail()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user