mirror of
https://github.com/httprunner/httprunner.git
synced 2026-08-28 03:30:01 +08:00
fix: TestSleepStrict
This commit is contained in:
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
# Release History
|
# Release History
|
||||||
|
|
||||||
## v4.3.6 (2023-08-22)
|
## v4.3.6 (2023-08-24)
|
||||||
|
|
||||||
**go version**
|
**go version**
|
||||||
|
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ func TestSleepStrict(t *testing.T) {
|
|||||||
sleepStrict(startTime, 1230)
|
sleepStrict(startTime, 1230)
|
||||||
dur := time.Since(startTime).Milliseconds()
|
dur := time.Since(startTime).Milliseconds()
|
||||||
t.Log(dur)
|
t.Log(dur)
|
||||||
if dur < 1230 || dur > 1232 {
|
if dur <= 1230 || dur > 1232 {
|
||||||
t.Fatal("sleepRandom failed")
|
t.Fatalf("sleepRandom failed, dur: %d", dur)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -53,10 +53,20 @@ func (o OCRResults) ToOCRTexts() (ocrTexts OCRTexts) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ImageResult struct {
|
type ImageResult struct {
|
||||||
URL string `json:"url"` // image uploaded url
|
URL string `json:"url"` // image uploaded url
|
||||||
OCRResult OCRResults `json:"ocrResult"` // OCR texts
|
OCRResult OCRResults `json:"ocrResult"` // OCR texts
|
||||||
LiveType string `json:"liveType"` // 直播间类型
|
// NoLive(非直播间)
|
||||||
UIResult UIResultMap `json:"uiResult"` // 图标检测
|
// Shop(电商)
|
||||||
|
// LifeService(生活服务)
|
||||||
|
// Show(秀场)
|
||||||
|
// Game(游戏)
|
||||||
|
// People(多人)
|
||||||
|
// PK(PK)
|
||||||
|
// Media(媒体)
|
||||||
|
// Chat(语音)
|
||||||
|
// Event(赛事)
|
||||||
|
LiveType string `json:"liveType"` // 直播间类型
|
||||||
|
UIResult UIResultMap `json:"uiResult"` // 图标检测
|
||||||
}
|
}
|
||||||
|
|
||||||
type APIResponseImage struct {
|
type APIResponseImage struct {
|
||||||
|
|||||||
Reference in New Issue
Block a user