mirror of
https://github.com/httprunner/httprunner.git
synced 2026-06-25 17:44:02 +08:00
fix: screen record duration
This commit is contained in:
@@ -1 +1 @@
|
||||
v5.0.0-beta-2503061750
|
||||
v5.0.0-beta-2503061758
|
||||
|
||||
@@ -792,6 +792,9 @@ func (ad *ADBDriver) ScreenRecord(opts ...option.ActionOption) (videoPath string
|
||||
}
|
||||
|
||||
duration := options.ScreenRecordDuration
|
||||
if duration == 0 {
|
||||
duration = options.Duration
|
||||
}
|
||||
audioOn := options.ScreenRecordWithAudio
|
||||
|
||||
// get android system version
|
||||
|
||||
@@ -195,7 +195,8 @@ func TestDriver_ADB_ForegroundInfo(t *testing.T) {
|
||||
|
||||
func TestDriver_ADB_ScreenRecord(t *testing.T) {
|
||||
driver := setupADBDriverExt(t)
|
||||
path1, err := driver.ScreenRecord(option.WithScreenRecordDuation(182))
|
||||
path1, err := driver.ScreenRecord(
|
||||
option.WithScreenRecordDuation(5))
|
||||
assert.Nil(t, err)
|
||||
defer os.Remove(path1)
|
||||
t.Log(path1)
|
||||
|
||||
Reference in New Issue
Block a user