未验证 提交 047807aa 编写于 作者: O openharmony_ci 提交者: Gitee

!5298 medialibrary用例名整改

Merge pull request !5298 from 秦莉文/master
...@@ -92,75 +92,75 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -92,75 +92,75 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
} }
} }
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_001 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_001
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON Image ASSET * @tc.desc : ON Image ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_001', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_001', 0, async function (done) {
let type = 'imageChange' let type = 'imageChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_001'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_001';
let currentFetchOps = fetchOps(testNum, 'Pictures/On/', IMAGE_TYPE); let currentFetchOps = fetchOps(testNum, 'Pictures/On/', IMAGE_TYPE);
await onTest(done, testNum, type, currentFetchOps) await onTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_002 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_002
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON Video ASSET * @tc.desc : ON Video ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_002', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_002', 0, async function (done) {
let type = 'videoChange' let type = 'videoChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_002'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_002';
let currentFetchOps = fetchOps(testNum, 'Videos/On/', VIDEO_TYPE); let currentFetchOps = fetchOps(testNum, 'Videos/On/', VIDEO_TYPE);
await onTest(done, testNum, type, currentFetchOps) await onTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_003 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_003
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON Audio ASSET * @tc.desc : ON Audio ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_003', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_003', 0, async function (done) {
let type = 'audioChange' let type = 'audioChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_003'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_003';
let currentFetchOps = fetchOps(testNum, 'Audios/On/', AUDIO_TYPE); let currentFetchOps = fetchOps(testNum, 'Audios/On/', AUDIO_TYPE);
await onTest(done, testNum, type, currentFetchOps) await onTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_004 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_004
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON File ASSET * @tc.desc : ON File ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_004', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_004', 0, async function (done) {
let type = 'fileChange' let type = 'fileChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_004'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_004';
let currentFetchOps = fetchOps(testNum, 'Documents/On/', FILE_TYPE); let currentFetchOps = fetchOps(testNum, 'Documents/On/', FILE_TYPE);
await onTest(done, testNum, type, currentFetchOps) await onTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_005 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_005
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON ALBUM * @tc.desc : ON ALBUM
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_005', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_005' let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_005'
try { try {
let conut = 0; let conut = 0;
media.on('albumChange', () => { media.on('albumChange', () => {
...@@ -187,15 +187,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -187,15 +187,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_006 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_006
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON DEVICE ASSET * @tc.desc : ON DEVICE ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_006', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_006' let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_006'
try { try {
let conut = 0; let conut = 0;
expect(true).assertTrue(); expect(true).assertTrue();
...@@ -225,15 +225,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -225,15 +225,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_006 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_006
* @tc.name : ON * @tc.name : ON
* @tc.desc : ON REMOTE_FILE ASSET * @tc.desc : ON REMOTE_FILE ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_007', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_007', 0, async function (done) {
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_ON_007' let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_ON_007'
try { try {
let conut = 0; let conut = 0;
expect(true).assertTrue(); expect(true).assertTrue();
...@@ -264,75 +264,75 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -264,75 +264,75 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_001 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_001
* @tc.name : off * @tc.name : off
* @tc.desc : off Image ASSET * @tc.desc : off Image ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_001', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_001', 0, async function (done) {
let type = 'imageChange' let type = 'imageChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_001'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_001';
let currentFetchOps = fetchOps(testNum, 'Pictures/Off/', IMAGE_TYPE); let currentFetchOps = fetchOps(testNum, 'Pictures/Off/', IMAGE_TYPE);
await offTest(done, testNum, type, currentFetchOps) await offTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_002 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_002
* @tc.name : off * @tc.name : off
* @tc.desc : off video ASSET * @tc.desc : off video ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_002', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_002', 0, async function (done) {
let type = 'videoChange' let type = 'videoChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_002'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_002';
let currentFetchOps = fetchOps(testNum, 'Videos/Off/', VIDEO_TYPE); let currentFetchOps = fetchOps(testNum, 'Videos/Off/', VIDEO_TYPE);
await offTest(done, testNum, type, currentFetchOps) await offTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_003 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_003
* @tc.name : off * @tc.name : off
* @tc.desc : off audio ASSET * @tc.desc : off audio ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_003', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_003', 0, async function (done) {
let type = 'audioChange' let type = 'audioChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_003'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_003';
let currentFetchOps = fetchOps(testNum, 'Audios/Off/', AUDIO_TYPE); let currentFetchOps = fetchOps(testNum, 'Audios/Off/', AUDIO_TYPE);
await offTest(done, testNum, type, currentFetchOps) await offTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_004 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_004
* @tc.name : off * @tc.name : off
* @tc.desc : off file ASSET * @tc.desc : off file ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_004', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_004', 0, async function (done) {
let type = 'fileChange' let type = 'fileChange'
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_004'; let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_004';
let currentFetchOps = fetchOps(testNum, 'Documents/Off/', FILE_TYPE); let currentFetchOps = fetchOps(testNum, 'Documents/Off/', FILE_TYPE);
await offTest(done, testNum, type, currentFetchOps) await offTest(done, testNum, type, currentFetchOps)
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_005 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_005
* @tc.name : off * @tc.name : off
* @tc.desc : off album * @tc.desc : off album
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_005', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_005' let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_005'
try { try {
let conut = 0; let conut = 0;
media.on('albumChange', () => { media.on('albumChange', () => {
...@@ -361,15 +361,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -361,15 +361,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
} }
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_006 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_006
* @tc.name : off * @tc.name : off
* @tc.desc : off device ASSET * @tc.desc : off device ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_006', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_006' let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_006'
try { try {
media.on('deviceChange', () => { media.on('deviceChange', () => {
console.info('MediaLibraryTest : off 006 failed'); console.info('MediaLibraryTest : off 006 failed');
...@@ -410,15 +410,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -410,15 +410,15 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_007 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_007
* @tc.name : off * @tc.name : off
* @tc.desc : off remoteFile ASSET * @tc.desc : off remoteFile ASSET
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_007', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_007', 0, async function (done) {
let testNum = 'SUB_MEDIA_MIDIALIBRARY_PROMISE_OFF_007' let testNum = 'SUB_MEDIA_MEDIALIBRARY_PROMISE_OFF_007'
try { try {
media.on('remoteFileChange', () => { media.on('remoteFileChange', () => {
console.info('MediaLibraryTest : off 007 failed'); console.info('MediaLibraryTest : off 007 failed');
...@@ -460,14 +460,14 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) { ...@@ -460,14 +460,14 @@ export default function mediaLibraryTestPromiseOnOffTest(abilityContext) {
}); });
/** /**
* @tc.number : SUB_MEDIA_MIDIALIBRARY_PROMISE_RELEASE_001 * @tc.number : SUB_MEDIA_MEDIALIBRARY_PROMISE_RELEASE_001
* @tc.name : release * @tc.name : release
* @tc.desc : Release MediaLibrary instance * @tc.desc : Release MediaLibrary instance
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_MIDIALIBRARY_PROMISE_RELEASE_001', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_PROMISE_RELEASE_001', 0, async function (done) {
try { try {
await media.release(); await media.release();
console.info('MediaLibraryTest : release 001 passed'); console.info('MediaLibraryTest : release 001 passed');
......
...@@ -85,15 +85,15 @@ export default function fileAssetCallback2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify displayName * @tc.desc : Modify displayName
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_callback_001', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK_001', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_callback_001' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK_001'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '01', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '01', IMAGE_TYPE);
let prop = 'displayName' let prop = 'displayName'
let val = new Date().getTime() + '.jpg' let val = new Date().getTime() + '.jpg'
...@@ -101,15 +101,15 @@ export default function fileAssetCallback2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify title * @tc.desc : Modify title
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_callback_002', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK_002', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_callback_002' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK_002'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '02', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '02', IMAGE_TYPE);
let prop = 'title' let prop = 'title'
let val = new Date().getTime() + 'newTitle' let val = new Date().getTime() + 'newTitle'
...@@ -117,15 +117,15 @@ export default function fileAssetCallback2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify relativePath * @tc.desc : Modify relativePath
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_callback_003', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK_003', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_callback_003' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_CALLBACK_003'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '03', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '03', IMAGE_TYPE);
let prop = 'relativePath' let prop = 'relativePath'
let val = 'Pictures/Temp/' let val = 'Pictures/Temp/'
...@@ -133,16 +133,16 @@ export default function fileAssetCallback2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify orientation * @tc.desc : Modify orientation
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @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 fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '04', IMAGE_TYPE);
let prop = 'orientation' let prop = 'orientation'
let val = 1 let val = 1
...@@ -150,16 +150,16 @@ export default function fileAssetCallback2Test(abilityContext) { ...@@ -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.name : isDirectory
* @tc.desc : isDirectory asset * @tc.desc : isDirectory asset
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @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 { 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); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyCb/', '05', IMAGE_TYPE);
const fetchFileResult = await media.getFileAssets(fetchOp); const fetchFileResult = await media.getFileAssets(fetchOp);
const asset = await fetchFileResult.getFirstObject(); const asset = await fetchFileResult.getFirstObject();
......
...@@ -96,15 +96,15 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify displayName * @tc.desc : Modify displayName
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_promise_001', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_001', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_promise_001' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_001'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '01', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '01', IMAGE_TYPE);
let prop = 'displayName' let prop = 'displayName'
let val = new Date().getTime() + '.jpg' let val = new Date().getTime() + '.jpg'
...@@ -112,15 +112,15 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify title * @tc.desc : Modify title
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_promise_002', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_002', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_promise_002' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_002'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '02', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '02', IMAGE_TYPE);
let prop = 'title' let prop = 'title'
let val = new Date().getTime() + 'newTitle' let val = new Date().getTime() + 'newTitle'
...@@ -128,15 +128,15 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify relativePath * @tc.desc : Modify relativePath
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_promise_003', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_003', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_promise_003' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_003'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '03', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '03', IMAGE_TYPE);
let prop = 'relativePath' let prop = 'relativePath'
let val = 'Pictures/Temp/' let val = 'Pictures/Temp/'
...@@ -144,15 +144,15 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify orientation * @tc.desc : Modify orientation
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_promise_004', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_004', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_promise_004' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_004'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '04', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '04', IMAGE_TYPE);
let prop = 'orientation' let prop = 'orientation'
let val = 1 let val = 1
...@@ -160,15 +160,15 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify uri * @tc.desc : Modify uri
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_promise_005', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_005', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_promise_005' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_005'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '06', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '06', IMAGE_TYPE);
let prop = 'uri' let prop = 'uri'
let val = 'newUri' let val = 'newUri'
...@@ -176,15 +176,15 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : commitModify
* @tc.desc : Modify mediaType * @tc.desc : Modify mediaType
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @tc.level : Level 0
*/ */
it('SUB_MEDIA_FILEASSET_commitModify_promise_006', 0, async function (done) { it('SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_006', 0, async function (done) {
let testNum = 'SUB_MEDIA_FILEASSET_commitModify_promise_006' let testNum = 'SUB_MEDIA_MEDIALIBRARY_FILEASSET_COMMITMODIFY_PROMISE_006'
let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '07', IMAGE_TYPE); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '07', IMAGE_TYPE);
let prop = 'mediaType' let prop = 'mediaType'
let val = 'newMediaType' let val = 'newMediaType'
...@@ -192,16 +192,16 @@ export default function fileAssetPromise2Test(abilityContext) { ...@@ -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.name : isDirectory
* @tc.desc : isDirectory asset * @tc.desc : isDirectory asset
* @tc.size : MEDIUM * @tc.size : MEDIUM
* @tc.type : Function * @tc.type : Function
* @tc.level : Level 0 * @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 { 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); let fetchOp = nameFetchOps(testNum, 'Pictures/ModifyPro/', '05', IMAGE_TYPE);
const fetchFileResult = await media.getFileAssets(fetchOp); const fetchFileResult = await media.getFileAssets(fetchOp);
const asset = await fetchFileResult.getFirstObject(); const asset = await fetchFileResult.getFirstObject();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册