Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
047807aa
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看板
未验证
提交
047807aa
编写于
8月 31, 2022
作者:
O
openharmony_ci
提交者:
Gitee
8月 31, 2022
浏览文件
操作
浏览文件
下载
差异文件
!5298 medialibrary用例名整改
Merge pull request !5298 from 秦莉文/master
上级
aebfb78b
b7abfa01
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
242 addition
and
242 deletion
+242
-242
multimedia/medialibrary/mediaLibrary_base/entry/src/main/ets/test/mediaLibraryTestCallback.test.ets
...entry/src/main/ets/test/mediaLibraryTestCallback.test.ets
+80
-80
multimedia/medialibrary/mediaLibrary_base/entry/src/main/ets/test/mediaLibraryTestPromise.test.ets
.../entry/src/main/ets/test/mediaLibraryTestPromise.test.ets
+82
-82
multimedia/medialibrary/mediaLibrary_base/entry/src/main/ets/test/mediaLibraryTestPromiseOnOff.test.ets
...y/src/main/ets/test/mediaLibraryTestPromiseOnOff.test.ets
+44
-44
multimedia/medialibrary/mediaLibrary_fileAsset/entry/src/main/ets/test/fileAssetCallback2.test.ets
...Asset/entry/src/main/ets/test/fileAssetCallback2.test.ets
+15
-15
multimedia/medialibrary/mediaLibrary_fileAsset/entry/src/main/ets/test/fileAssetPromise2.test.ets
...eAsset/entry/src/main/ets/test/fileAssetPromise2.test.ets
+21
-21
未找到文件。
multimedia/medialibrary/mediaLibrary_base/entry/src/main/ets/test/mediaLibraryTestCallback.test.ets
浏览文件 @
047807aa
...
...
@@ -298,15 +298,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
}
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_001
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_001'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
'image'
;
let
count
=
1
;
...
...
@@ -314,15 +314,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_002
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_002'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_002'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Videos/Static/'
,
VIDEO_TYPE
);
let
type
=
'video'
;
let
count
=
1
;
...
...
@@ -330,15 +330,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_003
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_003'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_003'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Audios/Static/'
,
AUDIO_TYPE
);
let
type
=
'audio'
;
let
count
=
1
;
...
...
@@ -346,15 +346,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_004
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_004'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_004'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Documents/Static/'
,
FILE_TYPE
);
let
type
=
'file'
;
let
count
=
1
;
...
...
@@ -362,15 +362,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_005
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_005'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_005'
;
let
currentFetchOps
=
imageAndVideofetchOp
;
let
type
=
'video'
;
let
count
=
2
;
...
...
@@ -379,15 +379,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_006
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_006'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_006'
;
let
currentFetchOps
=
imageAndVideoAndfilefetchOp
;
let
type
=
'file'
;
let
count
=
3
;
...
...
@@ -396,15 +396,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_007
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_006'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_006'
;
let
currentFetchOps
=
imageAndVideoAndfileAndAudiofetchOp
;
let
type
=
'audio'
;
let
count
=
4
;
...
...
@@ -413,157 +413,157 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_008
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_008
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_008'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_008'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
FILEKEY
.
MEDIA_TYPE
+
'= ?'
,
selectionArgs
:
[],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_008'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_008'
;
await
getFileAssetsZero
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_009
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_009
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_009'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_009'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
FILEKEY
.
MEDIA_TYPE
+
'abc= ?'
,
selectionArgs
:
[
AUDIO_TYPE
.
toString
()],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_009'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_009'
;
await
getFileAssetsAbnormal
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_010
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_010
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_010'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_010'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
FILEKEY
.
MEDIA_TYPE
+
'= ?'
,
selectionArgs
:
[
111
],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_010'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_010'
;
await
getFileAssetsZero
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_011
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_011
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_011'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_011'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
'abc'
+
'= ?'
,
selectionArgs
:
[
AUDIO_TYPE
.
toString
()],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETFILEASSETS_011'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETFILEASSETS_011'
;
await
getFileAssetsAbnormal
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_001
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_CAMERA
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_001'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_CAMERA
;
let
val
=
'Camera/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_002
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_VIDEO
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_002'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_002'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_VIDEO
;
let
val
=
'Videos/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_003
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_IMAGE
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_003'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_003'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_IMAGE
;
let
val
=
'Pictures/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_004
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_AUDIO
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_004'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_004'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_AUDIO
;
let
val
=
'Audios/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_005
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_IMAGE
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_005'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_005'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_DOCUMENTS
;
let
val
=
'Documents/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_006
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory 110
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_006'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_006'
,
0
,
async
function
(
done
)
{
try
{
await
media
.
getPublicDirectory
(
110
);
console
.
info
(
'MediaLibraryTest : getPublicDirectory 006 failed'
);
...
...
@@ -577,30 +577,30 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_007
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_DOWNLOAD
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_007'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_GETPUBLICDIRECTORY_007'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_DOWNLOAD
;
let
val
=
'Download/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_001
* @tc.name : createAsset
* @tc.desc : Create File Asset image (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_001'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
IMAGE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.jpg'
;
...
...
@@ -609,15 +609,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_002
* @tc.name : createAsset
* @tc.desc : Create File Asset image (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_002'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_002'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
IMAGE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.jpg'
;
...
...
@@ -627,15 +627,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_003
* @tc.name : createAsset
* @tc.desc : Create File Asset video (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_003'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_003'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Videos/Static/'
,
VIDEO_TYPE
);
let
type
=
VIDEO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp4'
;
...
...
@@ -644,15 +644,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_004
* @tc.name : createAsset
* @tc.desc : Create File Asset video (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_004'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_004'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Videos/Static/'
,
VIDEO_TYPE
);
let
type
=
VIDEO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp4'
;
...
...
@@ -661,15 +661,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_005
* @tc.name : createAsset
* @tc.desc : Create File Asset audio (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_005'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_005'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Audios/Static/'
,
AUDIO_TYPE
);
let
type
=
AUDIO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp3'
;
...
...
@@ -678,15 +678,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_006
* @tc.name : createAsset
* @tc.desc : Create File Asset audio (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_006'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_006'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Audios/Static/'
,
AUDIO_TYPE
);
let
type
=
AUDIO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp3'
;
...
...
@@ -695,15 +695,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_007
* @tc.name : createAsset
* @tc.desc : Create File Asset file (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_007'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_007'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Documents/Static/'
,
FILE_TYPE
);
let
type
=
FILE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.dat'
;
...
...
@@ -712,15 +712,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_008
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_008
* @tc.name : createAsset
* @tc.desc : Create File Asset file (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_008'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_008'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_008'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_008'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Documents/Static/'
,
FILE_TYPE
);
let
type
=
FILE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.dat'
;
...
...
@@ -729,15 +729,15 @@ export default function mediaLibraryTestCallback(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_001
* @tc.name : createAsset
* @tc.desc : Create File Asset image (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_009'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_CALLBACK_CREATEASSET_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_009'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_CALLBACK_CREATEASSET_001'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
IMAGE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.jpg'
;
...
...
multimedia/medialibrary/mediaLibrary_base/entry/src/main/ets/test/mediaLibraryTestPromise.test.ets
浏览文件 @
047807aa
...
...
@@ -258,14 +258,14 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
}
}
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETMEDIALIBRAY_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETMEDIALIBRAY_001
* @tc.name : getMediaLibrary
* @tc.desc : Obtains a MediaLibrary instance
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETMEDIALIBRAY_001'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETMEDIALIBRAY_001'
,
0
,
async
function
(
done
)
{
try
{
expect
(
media
!=
undefined
)
.
assertTrue
();
done
();
...
...
@@ -277,15 +277,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_001
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_001'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
'image'
;
let
count
=
1
;
...
...
@@ -293,15 +293,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_002
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_002'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_002'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Videos/Static/'
,
VIDEO_TYPE
);
let
type
=
'video'
;
let
count
=
1
;
...
...
@@ -309,15 +309,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_003
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_003'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_003'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Audios/Static/'
,
AUDIO_TYPE
);
let
type
=
'audio'
;
let
count
=
1
;
...
...
@@ -325,15 +325,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_004
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_004'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_004'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Documents/Static/'
,
FILE_TYPE
);
let
type
=
'file'
;
let
count
=
1
;
...
...
@@ -341,15 +341,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_005
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_005'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_005'
;
let
currentFetchOps
=
imageAndVideofetchOp
;
let
type
=
'video'
;
let
count
=
2
;
...
...
@@ -358,15 +358,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_006
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_006'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_006'
;
let
currentFetchOps
=
imageAndVideoAndfilefetchOp
;
let
type
=
'file'
;
let
count
=
3
;
...
...
@@ -375,15 +375,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_007
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_006'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_006'
;
let
currentFetchOps
=
imageAndVideoAndfileAndAudiofetchOp
;
let
type
=
'audio'
;
let
count
=
4
;
...
...
@@ -392,157 +392,157 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_008
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_008
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_008'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_008'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
FILEKEY
.
MEDIA_TYPE
+
'= ?'
,
selectionArgs
:
[],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_008'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_008'
;
await
getFileAssetsZero
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_009
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_009
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_009'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_009'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
FILEKEY
.
MEDIA_TYPE
+
'abc= ?'
,
selectionArgs
:
[
AUDIO_TYPE
.
toString
()],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_009'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_009'
;
await
getFileAssetsAbnormal
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_010
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_010
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_010'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_010'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
FILEKEY
.
MEDIA_TYPE
+
'= ?'
,
selectionArgs
:
[
111
],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_010'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_010'
;
await
getFileAssetsZero
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_011
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_011
* @tc.name : getFileAssets
* @tc.desc : query all assets
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_011'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_011'
,
0
,
async
function
(
done
)
{
let
currentFetchOps
=
{
selections
:
'abc'
+
'= ?'
,
selectionArgs
:
[
AUDIO_TYPE
.
toString
()],
};
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETFILEASSETS_011'
;
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETFILEASSETS_011'
;
await
getFileAssetsAbnormal
(
done
,
testNum
,
currentFetchOps
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_001
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_CAMERA
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_001'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_CAMERA
;
let
val
=
'Camera/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_002
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_VIDEO
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_002'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_002'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_VIDEO
;
let
val
=
'Videos/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_003
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_IMAGE
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_003'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_003'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_IMAGE
;
let
val
=
'Pictures/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_004
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_AUDIO
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_004'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_004'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_AUDIO
;
let
val
=
'Audios/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_005
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_DOCUMENTS
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_005'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_005'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_DOCUMENTS
;
let
val
=
'Documents/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_006
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory 110
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_006'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_006'
,
0
,
async
function
(
done
)
{
try
{
await
media
.
getPublicDirectory
(
110
);
console
.
info
(
'MediaLibraryTest : getPublicDirectory 006 failed'
);
...
...
@@ -556,15 +556,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_007
* @tc.name : getPublicDirectory
* @tc.desc : getPublicDirectory DIR_DOWNLOAD
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_007'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_GETPUBLICDIRECTORY_007'
;
let
dir
=
mediaLibrary
.
DirectoryType
.
DIR_DOWNLOAD
;
let
val
=
'Download/'
;
await
checkGetPublicDirectory
(
done
,
testNum
,
dir
,
val
)
...
...
@@ -572,15 +572,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_001
* @tc.name : createAsset
* @tc.desc : Create File Asset image (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_001'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_001'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
IMAGE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.jpg'
;
...
...
@@ -589,15 +589,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_002
* @tc.name : createAsset
* @tc.desc : Create File Asset image (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_002'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_002'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_002'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
IMAGE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.jpg'
;
...
...
@@ -607,15 +607,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_003
* @tc.name : createAsset
* @tc.desc : Create File Asset video (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_003'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_003'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_003'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Videos/Static/'
,
VIDEO_TYPE
);
let
type
=
VIDEO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp4'
;
...
...
@@ -624,15 +624,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_004
* @tc.name : createAsset
* @tc.desc : Create File Asset video (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_004'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_004'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_004'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Videos/Static/'
,
VIDEO_TYPE
);
let
type
=
VIDEO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp4'
;
...
...
@@ -641,15 +641,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_005
* @tc.name : createAsset
* @tc.desc : Create File Asset audio (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_005'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_005'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_005'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Audios/Static/'
,
AUDIO_TYPE
);
let
type
=
AUDIO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp3'
;
...
...
@@ -658,15 +658,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_006
* @tc.name : createAsset
* @tc.desc : Create File Asset audio (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_006'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_006'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_006'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Audios/Static/'
,
AUDIO_TYPE
);
let
type
=
AUDIO_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.mp3'
;
...
...
@@ -675,15 +675,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_007
* @tc.name : createAsset
* @tc.desc : Create File Asset file (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_007'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_007'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_007'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Documents/Static/'
,
FILE_TYPE
);
let
type
=
FILE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.dat'
;
...
...
@@ -692,15 +692,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_008
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_008
* @tc.name : createAsset
* @tc.desc : Create File Asset file (existed)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_008'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_008'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_008'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_008'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Documents/Static/'
,
FILE_TYPE
);
let
type
=
FILE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.dat'
;
...
...
@@ -709,15 +709,15 @@ export default function mediaLibraryTestPromiseTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_001
* @tc.name : createAsset
* @tc.desc : Create File Asset image (does not exist)
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it
(
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_009'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_CREATEASSET_001'
;
it
(
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_009'
,
0
,
async
function
(
done
)
{
let
testNum
=
'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_CREATEASSET_001'
;
let
currentFetchOps
=
fetchOps
(
testNum
,
'Pictures/Static/'
,
IMAGE_TYPE
);
let
type
=
IMAGE_TYPE
;
let
name
=
new
Date
()
.
getTime
()
+
'.jpg'
;
...
...
multimedia/medialibrary/mediaLibrary_base/entry/src/main/ets/test/mediaLibraryTestPromiseOnOff.test.ets
浏览文件 @
047807aa
...
...
@@ -92,75 +92,75 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}
}
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_001
* @tc.name : ON
* @tc.desc : ON Image ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_001', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_001', 0, async function (done) {
let type = 'imageChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_001';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_001';
let currentFetchOps = fetchOps(testNum, 'Pictures/On/', IMAGE_TYPE);
await onTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_002
* @tc.name : ON
* @tc.desc : ON Video ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_002', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_002', 0, async function (done) {
let type = 'videoChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_002';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_002';
let currentFetchOps = fetchOps(testNum, 'Videos/On/', VIDEO_TYPE);
await onTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_003
* @tc.name : ON
* @tc.desc : ON Audio ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_003', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_003', 0, async function (done) {
let type = 'audioChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_003';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_003';
let currentFetchOps = fetchOps(testNum, 'Audios/On/', AUDIO_TYPE);
await onTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_004
* @tc.name : ON
* @tc.desc : ON File ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_004', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_004', 0, async function (done) {
let type = 'fileChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_004';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_004';
let currentFetchOps = fetchOps(testNum, 'Documents/On/', FILE_TYPE);
await onTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_005
* @tc.name : ON
* @tc.desc : ON ALBUM
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_005'
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_005'
try {
let conut = 0;
media.on('albumChange', () => {
...
...
@@ -187,15 +187,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_006
* @tc.name : ON
* @tc.desc : ON DEVICE ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_006'
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_006'
try {
let conut = 0;
expect(true).assertTrue();
...
...
@@ -225,15 +225,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_006
* @tc.name : ON
* @tc.desc : ON REMOTE_FILE ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_007', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_ON_007'
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_007', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_ON_007'
try {
let conut = 0;
expect(true).assertTrue();
...
...
@@ -264,75 +264,75 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_001
* @tc.name : off
* @tc.desc : off Image ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_001', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_001', 0, async function (done) {
let type = 'imageChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_001';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_001';
let currentFetchOps = fetchOps(testNum, 'Pictures/Off/', IMAGE_TYPE);
await offTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_002
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_002
* @tc.name : off
* @tc.desc : off video ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_002', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_002', 0, async function (done) {
let type = 'videoChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_002';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_002';
let currentFetchOps = fetchOps(testNum, 'Videos/Off/', VIDEO_TYPE);
await offTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_003
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_003
* @tc.name : off
* @tc.desc : off audio ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_003', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_003', 0, async function (done) {
let type = 'audioChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_003';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_003';
let currentFetchOps = fetchOps(testNum, 'Audios/Off/', AUDIO_TYPE);
await offTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_004
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_004
* @tc.name : off
* @tc.desc : off file ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_004', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_004', 0, async function (done) {
let type = 'fileChange'
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_004';
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_004';
let currentFetchOps = fetchOps(testNum, 'Documents/Off/', FILE_TYPE);
await offTest(done, testNum, type, currentFetchOps)
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_005
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_005
* @tc.name : off
* @tc.desc : off album
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_005'
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_005'
try {
let conut = 0;
media.on('albumChange', () => {
...
...
@@ -361,15 +361,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_006
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_006
* @tc.name : off
* @tc.desc : off device ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_006'
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_006'
try {
media.on('deviceChange', () => {
console.info('MediaLibraryTest : off 006 failed');
...
...
@@ -410,15 +410,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_007
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_007
* @tc.name : off
* @tc.desc : off remoteFile ASSET
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_007', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
I
DIALIBRARY_PROMISE_OFF_007'
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_007', 0, async function (done) {
let testNum = 'SUB_MEDIA_M
E
DIALIBRARY_PROMISE_OFF_007'
try {
media.on('remoteFileChange', () => {
console.info('MediaLibraryTest : off 007 failed');
...
...
@@ -460,14 +460,14 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_M
I
DIALIBRARY_PROMISE_RELEASE_001
* @tc.number : SUB_MEDIA_M
E
DIALIBRARY_PROMISE_RELEASE_001
* @tc.name : release
* @tc.desc : Release MediaLibrary instance
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_M
I
DIALIBRARY_PROMISE_RELEASE_001', 0, async function (done) {
it('SUB_MEDIA_M
E
DIALIBRARY_PROMISE_RELEASE_001', 0, async function (done) {
try {
await media.release();
console.info('MediaLibraryTest : release 001 passed');
...
...
multimedia/medialibrary/mediaLibrary_fileAsset/entry/src/main/ets/test/fileAssetCallback2.test.ets
浏览文件 @
047807aa
...
...
@@ -85,15 +85,15 @@ export default function fileAssetCallback2Test(abilityContext) {
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_callback
_001
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_001
* @tc.name : commitModify
* @tc.desc : Modify displayName
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_callback
_001', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_callback
_001'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_001', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_001'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '01', IMAGE_TYPE);
let prop = 'displayName'
let val = new Date().getTime() + '.jpg'
...
...
@@ -101,15 +101,15 @@ export default function fileAssetCallback2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_callback
_002
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_002
* @tc.name : commitModify
* @tc.desc : Modify title
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_callback
_002', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_callback
_002'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_002', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_002'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '02', IMAGE_TYPE);
let prop = 'title'
let val = new Date().getTime() + 'newTitle'
...
...
@@ -117,15 +117,15 @@ export default function fileAssetCallback2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_callback
_003
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_003
* @tc.name : commitModify
* @tc.desc : Modify relativePath
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_callback
_003', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_callback
_003'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_003', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_003'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '03', IMAGE_TYPE);
let prop = 'relativePath'
let val = 'Pictures/Temp/'
...
...
@@ -133,16 +133,16 @@ export default function fileAssetCallback2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_callback
_004
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_004
* @tc.name : commitModify
* @tc.desc : Modify orientation
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_callback
_004', 0, async function (done) {
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_004', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_callback
_004'
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK
_004'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '04', IMAGE_TYPE);
let prop = 'orientation'
let val = 1
...
...
@@ -150,16 +150,16 @@ export default function fileAssetCallback2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_isDirectory_callback
_001
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_ISDIRECTORY_CALLBACK
_001
* @tc.name : isDirectory
* @tc.desc : isDirectory asset
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_isDirectory_callback
_001', 0, async function (done) {
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_ISDIRECTORY_CALLBACK
_001', 0, async function (done) {
try {
let testNum = 'SUB_MEDIA_
FILEASSET_isDirectory_callback
_001'
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_ISDIRECTORY_CALLBACK
_001'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '05', IMAGE_TYPE);
const fetchFileResult = await media.getFileAssets(fetchOp);
const asset = await fetchFileResult.getFirstObject();
...
...
multimedia/medialibrary/mediaLibrary_fileAsset/entry/src/main/ets/test/fileAssetPromise2.test.ets
浏览文件 @
047807aa
...
...
@@ -96,15 +96,15 @@ export default function fileAssetPromise2Test(abilityContext) {
}
}
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_promise
_001
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_001
* @tc.name : commitModify
* @tc.desc : Modify displayName
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_promise
_001', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_promise
_001'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_001', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_001'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '01', IMAGE_TYPE);
let prop = 'displayName'
let val = new Date().getTime() + '.jpg'
...
...
@@ -112,15 +112,15 @@ export default function fileAssetPromise2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_promise
_002
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_002
* @tc.name : commitModify
* @tc.desc : Modify title
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_promise
_002', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_promise
_002'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_002', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_002'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '02', IMAGE_TYPE);
let prop = 'title'
let val = new Date().getTime() + 'newTitle'
...
...
@@ -128,15 +128,15 @@ export default function fileAssetPromise2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_promise
_003
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_003
* @tc.name : commitModify
* @tc.desc : Modify relativePath
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_promise
_003', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_promise
_003'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_003', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_003'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '03', IMAGE_TYPE);
let prop = 'relativePath'
let val = 'Pictures/Temp/'
...
...
@@ -144,15 +144,15 @@ export default function fileAssetPromise2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_promise
_004
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_004
* @tc.name : commitModify
* @tc.desc : Modify orientation
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_promise
_004', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_promise
_004'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_004', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_004'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '04', IMAGE_TYPE);
let prop = 'orientation'
let val = 1
...
...
@@ -160,15 +160,15 @@ export default function fileAssetPromise2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_promise
_005
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_005
* @tc.name : commitModify
* @tc.desc : Modify uri
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_promise
_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_promise
_005'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_005'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '06', IMAGE_TYPE);
let prop = 'uri'
let val = 'newUri'
...
...
@@ -176,15 +176,15 @@ export default function fileAssetPromise2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_commitModify_promise
_006
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_006
* @tc.name : commitModify
* @tc.desc : Modify mediaType
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_commitModify_promise
_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_
FILEASSET_commitModify_promise
_006'
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE
_006'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '07', IMAGE_TYPE);
let prop = 'mediaType'
let val = 'newMediaType'
...
...
@@ -192,16 +192,16 @@ export default function fileAssetPromise2Test(abilityContext) {
});
/**
* @tc.number : SUB_MEDIA_
FILEASSET_isDirectory_promise
_001
* @tc.number : SUB_MEDIA_
MEDIALIBRARY_FILEASSET_ISDIRECTORY_PROMISE
_001
* @tc.name : isDirectory
* @tc.desc : isDirectory asset
* @tc.size : MEDIUM
* @tc.type : Function
* @tc.level : Level 0
*/
it('SUB_MEDIA_
FILEASSET_isDirectory_promise
_001', 0, async function (done) {
it('SUB_MEDIA_
MEDIALIBRARY_FILEASSET_ISDIRECTORY_PROMISE
_001', 0, async function (done) {
try {
let testNum = 'SUB_MEDIA_
FILEASSET_isDirectory_promise
_001'
let testNum = 'SUB_MEDIA_
MEDIALIBRARY_FILEASSET_ISDIRECTORY_PROMISE
_001'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '05', IMAGE_TYPE);
const fetchFileResult = await media.getFileAssets(fetchOp);
const asset = await fetchFileResult.getFirstObject();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录