Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
a476a617
X
Xts Acts
项目概览
OpenHarmony
/
Xts Acts
1 年多 前同步成功
通知
9
Star
22
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
X
Xts Acts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
a476a617
编写于
5月 06, 2023
作者:
O
openharmony_ci
提交者:
Gitee
5月 06, 2023
浏览文件
操作
浏览文件
下载
差异文件
!8532 avPlayer问题修复 用例时长优化 avRecorder用例上库
Merge pull request !8532 from Nicklaus/master
上级
67c186fb
35c8badd
变更
5
展开全部
隐藏空白更改
内联
并排
Showing
5 changed file
with
1299 addition
and
666 deletion
+1299
-666
multimedia/media/media_js_standard/AVPlayerTestBase.js
multimedia/media/media_js_standard/AVPlayerTestBase.js
+11
-15
multimedia/media/media_js_standard/AVRecorderTestBase.js
multimedia/media/media_js_standard/AVRecorderTestBase.js
+289
-639
multimedia/media/media_js_standard/avPlayer/entry/src/main/ets/test/AVPlayerStabilityTest.test.js
...yer/entry/src/main/ets/test/AVPlayerStabilityTest.test.js
+8
-8
multimedia/media/media_js_standard/avRecorder/Test.json
multimedia/media/media_js_standard/avRecorder/Test.json
+3
-3
multimedia/media/media_js_standard/avRecorder/src/main/js/test/AVRecorderFuncTest.test.js
...rd/avRecorder/src/main/js/test/AVRecorderFuncTest.test.js
+988
-1
未找到文件。
multimedia/media/media_js_standard/AVPlayerTestBase.js
浏览文件 @
a476a617
...
...
@@ -425,7 +425,6 @@ function setAVPlayerPlayAndPauseWithCallBack(src, avPlayer, playTime, done) {
console
.
info
(
'
playPauseLoopWithCallBack avPlayer from play to stop
'
)
avPlayer
.
release
().
then
(()
=>
{
console
.
info
(
'
playPauseLoopWithCallBack avPlayer from stop to release
'
)
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
error
'
]);
done
();
},
mediaTestBase
.
failureCallback
).
catch
(
mediaTestBase
.
catchCallback
);
},
mediaTestBase
.
failureCallback
).
catch
(
mediaTestBase
.
catchCallback
);
...
...
@@ -556,7 +555,6 @@ async function playToCompletedLoop(src, avPlayer, done) {
console
.
info
(
'
playToCompletedLoop avPlayer from play to stop
'
)
avPlayer
.
release
().
then
(()
=>
{
console
.
info
(
'
playToCompletedLoop avPlayer from stop to release
'
)
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
error
'
]);
done
();
},
mediaTestBase
.
failureCallback
).
catch
(
mediaTestBase
.
catchCallback
);
},
mediaTestBase
.
failureCallback
).
catch
(
mediaTestBase
.
catchCallback
);
...
...
@@ -621,7 +619,6 @@ export async function seekLoop(src, avPlayer, done) {
}
await
avPlayer
.
stop
().
then
(()
=>
{
console
.
info
(
'
seekLoopWithCallback avPlayer from play to stop
'
)
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
seekDone
'
]);
avPlayer
.
release
().
then
(()
=>
{
console
.
info
(
'
seekLoopWithCallback avPlayer from stop to release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
...
...
@@ -767,15 +764,12 @@ export async function createToReleaseLoop(src, avPlayer, done) {
await
avPlayer
.
release
().
then
(()
=>
{
console
.
info
(
'
createToReleaseLoop avPlayer from stop to release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
if
(
i
==
999
){
done
();
}
},
mediaTestBase
.
failureCallback
).
catch
(
mediaTestBase
.
catchCallback
);
console
.
info
(
`case createToReleaseLoop loop is
${
i
}
`
);
}
await
avPlayer
.
release
().
then
(()
=>
{
console
.
info
(
'
createToReleaseLoop avPlayer from stop to release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
done
();
},
mediaTestBase
.
failureCallback
).
catch
(
mediaTestBase
.
catchCallback
);
}
let
createLoopTime
=
0
;
...
...
@@ -785,7 +779,7 @@ export async function createTimeWithCallback(src, avPlayer, done) {
avPlayer
=
await
idle
(
src
,
avPlayer
)
createStart
=
Date
.
now
();
console
.
info
(
`createTimeWithCallback createStart time is :
${
createStart
}
`
)
createTime
With
Callback
(
src
,
avPlayer
,
done
)
createTimeCallback
(
src
,
avPlayer
,
done
)
}
function
createTimeCallback
(
src
,
avPlayer
,
done
){
...
...
@@ -1778,7 +1772,6 @@ function setSpeedTimeCallback(avPlayer, done) {
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
PLAYING
);
if
(
loopTime
==
10
){
avPlayer
.
release
().
then
(()
=>
{
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
error
'
]);
console
.
info
(
'
setSpeedTimeCallback avPlayer is release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
let
avg
=
totalTime
/
10
;
...
...
@@ -1889,7 +1882,6 @@ function setBitrateTimeCallback(avPlayer, done) {
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
PLAYING
);
if
(
loopTime
==
10
){
avPlayer
.
release
().
then
(()
=>
{
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
error
'
]);
console
.
info
(
'
setBitrateTimeCallback avPlayer is release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
let
avg
=
totalTime
/
10
;
...
...
@@ -2001,7 +1993,6 @@ function setVolumeTimeCallback(avPlayer, done) {
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
PLAYING
);
if
(
loopTime
==
10
){
avPlayer
.
release
().
then
(()
=>
{
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
error
'
]);
console
.
info
(
'
setVolumeTimeCallback avPlayer is release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
let
avg
=
totalTime
/
10
;
...
...
@@ -2058,7 +2049,6 @@ export async function firstFrameTime(src, avPlayer, done) {
console
.
info
(
"
firstFrameTime execution time is :
"
+
execution
)
sleep
(
100
)
avPlayer
.
release
().
then
(()
=>
{
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
startRenderFrame
'
]);
console
.
info
(
'
firstFrameTime avPlayer is release
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
RELEASED
);
avPlayer
=
null
;
...
...
@@ -2122,6 +2112,13 @@ function setAVPlayerPlay(src, avPlayer, done) {
case
AV_PLAYER_STATE
.
PLAYING
:
console
.
info
(
'
setAVPlayerPlay play state is PLAYING
'
)
expect
(
avPlayer
.
state
).
assertEqual
(
AV_PLAYER_STATE
.
PLAYING
);
if
(
avPlayer
.
duration
>
3000
){
mediaTestBase
.
msleepAsync
(
3000
);
avPlayer
.
seek
(
avPlayer
.
duration
,
media
.
SeekMode
.
SEEK_NEXT_SYNC
)
}
else
{
mediaTestBase
.
msleepAsync
(
500
);
avPlayer
.
seek
(
avPlayer
.
duration
,
media
.
SeekMode
.
SEEK_NEXT_SYNC
)
}
break
;
case
AV_PLAYER_STATE
.
COMPLETED
:
expect
(
avPlayer
.
currentTime
).
assertEqual
(
avPlayer
.
duration
);
...
...
@@ -2131,7 +2128,6 @@ function setAVPlayerPlay(src, avPlayer, done) {
break
;
case
AV_PLAYER_STATE
.
RELEASED
:
expect
(
avPlayer
.
state
).
assertEqual
(
'
released
'
);
offCallback
(
avPlayer
,
[
'
stateChange
'
,
'
error
'
]);
avPlayer
=
null
;
done
();
break
;
...
...
multimedia/media/media_js_standard/AVRecorderTestBase.js
浏览文件 @
a476a617
此差异已折叠。
点击以展开。
multimedia/media/media_js_standard/avPlayer/entry/src/main/ets/test/AVPlayerStabilityTest.test.js
浏览文件 @
a476a617
...
...
@@ -887,14 +887,14 @@ export default function AVPlayerStabilityTest() {
console
.
info
(
TAG
+
'
SUB_MULTIMEDIA_MEDIA_AVPLAYER_STABILITY_01_0800 end
'
)
})
/* *
* @tc.number : SUB_MULTIMEDIA_MEDIA_AVPLAYER_PERFORMANCE_01_0100
* @tc.name : 001.test create time (wait callback)
* @tc.desc : Local Video test create time (wait callback)
* @tc.size : MediumTest
* @tc.type : Function test
* @tc.level : Level3
*/
//
/* *
//
* @tc.number : SUB_MULTIMEDIA_MEDIA_AVPLAYER_PERFORMANCE_01_0100
//
* @tc.name : 001.test create time (wait callback)
//
* @tc.desc : Local Video test create time (wait callback)
//
* @tc.size : MediumTest
//
* @tc.type : Function test
//
* @tc.level : Level3
//
*/
// it('SUB_MULTIMEDIA_MEDIA_AVPLAYER_PERFORMANCE_01_0100', 0, async function (done) {
// console.info(TAG + 'SUB_MULTIMEDIA_MEDIA_AVPLAYER_PERFORMANCE_01_0100 start')
// AVPlayerTestBase.createTimeWithCallback(videos[0], avPlayer, done);
...
...
multimedia/media/media_js_standard/avRecorder/Test.json
浏览文件 @
a476a617
...
...
@@ -2,9 +2,9 @@
"description"
:
"Configuration for avRecorder Tests"
,
"driver"
:
{
"type"
:
"OHJSUnitTest"
,
"test-timeout"
:
"
2
000000"
,
"shell-timeout"
:
"
2
000000"
,
"testcase-timeout"
:
1
5
0000
,
"test-timeout"
:
"
6
000000"
,
"shell-timeout"
:
"
6
000000"
,
"testcase-timeout"
:
1
10
0000
,
"bundle-name"
:
"ohos.acts.multimedia.audio.avrecorder"
,
"package-name"
:
"ohos.acts.multimedia.audio.avrecorder"
},
...
...
multimedia/media/media_js_standard/avRecorder/src/main/js/test/AVRecorderFuncTest.test.js
浏览文件 @
a476a617
此差异已折叠。
点击以展开。
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录