From c33dde1f155e19c02b1a2568eb00821bd62d825f Mon Sep 17 00:00:00 2001 From: qinliwen Date: Tue, 27 Dec 2022 18:07:01 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E4=BE=8B=E6=95=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: qinliwen --- .../src/main/js/test/AudioRenderer.test.js | 1 + .../src/main/js/test/fileAssetTestCallback.test.js | 12 ++++++------ .../src/main/js/test/fileAssetTestPromise.test.js | 12 ++++++------ .../src/main/js/test/fileTestPromise.test.js | 4 ++-- .../main/js/test/mediaLibraryTestCallBack.test.js | 4 ++-- .../src/main/js/test/mediaLibraryTestPromise.test.js | 4 ++-- 6 files changed, 19 insertions(+), 18 deletions(-) diff --git a/multimedia/audio/audio_js_standard/audioManager/src/main/js/test/AudioRenderer.test.js b/multimedia/audio/audio_js_standard/audioManager/src/main/js/test/AudioRenderer.test.js index 037c3444b..38bd304b2 100644 --- a/multimedia/audio/audio_js_standard/audioManager/src/main/js/test/AudioRenderer.test.js +++ b/multimedia/audio/audio_js_standard/audioManager/src/main/js/test/AudioRenderer.test.js @@ -1331,6 +1331,7 @@ describe('audioRenderer', function () { audioRen = data; } }); + await sleep(100); console.log(`isPass: ${isPass}`); if (isPass) { resultFlag = true; diff --git a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestCallback.test.js b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestCallback.test.js index ca42b102b..c6ce2e8fd 100644 --- a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestCallback.test.js +++ b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestCallback.test.js @@ -639,8 +639,8 @@ describe('fileAssetTestCallback.test.js', async function() { try { let fileType = mediaLibrary.MediaType.VIDEO; let fileFetchOp = { - selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs : [ fileType.toString() ], + selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs : [ fileType.toString(), '01.mp4' ], }; let fetchFileResult = await media.getFileAssets(fileFetchOp); const dataList = await fetchFileResult.getAllObject(); @@ -708,8 +708,8 @@ describe('fileAssetTestCallback.test.js', async function() { try { let type = mediaLibrary.MediaType.VIDEO; let fetchOp = { - selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs : [ type.toString() ], + selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs : [ type.toString(), '01.mp4' ], }; let fetchFileResult = await media.getFileAssets(fetchOp); const dataList = await fetchFileResult.getAllObject(); @@ -773,8 +773,8 @@ describe('fileAssetTestCallback.test.js', async function() { try { let type = mediaLibrary.MediaType.VIDEO; let fetchOp = { - selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs : [ type.toString() ], + selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs : [ type.toString(), '01.mp4' ], }; let fetchFileResult = await media.getFileAssets(fetchOp); const dataList = await fetchFileResult.getAllObject(); diff --git a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestPromise.test.js b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestPromise.test.js index 090c81ebe..ecaf75eb3 100644 --- a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestPromise.test.js +++ b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileAssetTestPromise.test.js @@ -458,8 +458,8 @@ describe('fileAssetTestPromise.test.js', async function() { try { let fileType = mediaLibrary.MediaType.VIDEO; let fileFetchOp = { - selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs : [ fileType.toString()], + selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs : [ fileType.toString(), '01.mp4' ], }; let fetchFileResult = await media.getFileAssets(fileFetchOp); const dataList = await fetchFileResult.getAllObject(); @@ -517,8 +517,8 @@ describe('fileAssetTestPromise.test.js', async function() { try { let type = mediaLibrary.MediaType.VIDEO; let fetchOp = { - selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs : [ type.toString() ], + selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs : [ type.toString(), '01.mp4' ], }; let fetchFileResult = await media.getFileAssets(fetchOp); const dataList = await fetchFileResult.getAllObject(); @@ -561,8 +561,8 @@ describe('fileAssetTestPromise.test.js', async function() { try { let type = mediaLibrary.MediaType.VIDEO; let fetchOp = { - selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs : [ type.toString() ], + selections : mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs : [ type.toString(), '01.mp4' ], }; let fetchFileResult = await media.getFileAssets(fetchOp); const dataList = await fetchFileResult.getAllObject(); diff --git a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileTestPromise.test.js b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileTestPromise.test.js index f464e88cf..72cfe8344 100644 --- a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileTestPromise.test.js +++ b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/fileTestPromise.test.js @@ -29,8 +29,8 @@ let imagesfetchOp = { selectionArgs: [imageType.toString()], }; let videosfetchOp = { - selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs: [videoType.toString()], + selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs: [videoType.toString(), '01.mp4'], }; let audiosfetchOp = { selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND bucket_display_name = ?', diff --git a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestCallBack.test.js b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestCallBack.test.js index 158f90513..af33f957c 100644 --- a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestCallBack.test.js +++ b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestCallBack.test.js @@ -40,8 +40,8 @@ let imagesfetchOp = { selectionArgs: [imageType.toString()], }; let videosfetchOp = { - selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs: [videoType.toString()], + selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs: [videoType.toString(), '01.mp4'], }; let audiosfetchOp = { selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND bucket_display_name = ?', diff --git a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestPromise.test.js b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestPromise.test.js index 65bae0d5d..25be293f3 100644 --- a/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestPromise.test.js +++ b/multimedia/medialibrary/mediaLibrary_js_standard/src/main/js/test/mediaLibraryTestPromise.test.js @@ -40,8 +40,8 @@ let imagesfetchOp = { selectionArgs: [imageType.toString()], }; let videosfetchOp = { - selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ?', - selectionArgs: [videoType.toString()], + selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND display_name = ?', + selectionArgs: [videoType.toString(), '01.mp4'], }; let audiosfetchOp = { selections: mediaLibrary.FileKey.MEDIA_TYPE + '= ? AND bucket_display_name = ?', -- GitLab