提交 658dbbd2 编写于 作者: Z zhang-daiyue

Fix FileAsset.relative_path test case

Signed-off-by: Nzhang-daiyue <zhangdaiyue1@huawei.com>
Change-Id: I3c8987c7475400ad11b9a300426bb68ed00a8594
上级 7056046d
......@@ -137,16 +137,10 @@ describe('fileAssetCallBack2.test.js', async function () {
it('SUB_MEDIA_FILEASSET_commitModify_callback_003', 0, async function (done) {
try {
const path1 = await media.getPublicDirectory(mediaLibrary.DirectoryType.DIR_IMAGE);
const path2 = await media.getPublicDirectory(mediaLibrary.DirectoryType.DIR_VIDEO);
const fetchFileResult = await media.getFileAssets(imagesfetchOp);
const asset = await fetchFileResult.getFirstObject();
let relativePath = asset.relativePath;
let newrelativePath = path1;
if (relativePath == path1) {
newrelativePath = path2;
}
let newrelativePath = path1 + "new/";
asset.relativePath = newrelativePath;
const id = asset.id;
......
......@@ -135,16 +135,10 @@ describe('fileAssetPromise2.test.js', async function () {
it('SUB_MEDIA_FILEASSET_commitModify_promise_003', 0, async function (done) {
try {
const path1 = await media.getPublicDirectory(mediaLibrary.DirectoryType.DIR_IMAGE);
const path2 = await media.getPublicDirectory(mediaLibrary.DirectoryType.DIR_VIDEO);
const fetchFileResult = await media.getFileAssets(imagesfetchOp);
const asset = await fetchFileResult.getFirstObject();
let relativePath = asset.relativePath;
let newrelativePath = path1;
if (relativePath == path1) {
newrelativePath = path2;
}
let newrelativePath = path1 + "new/";
asset.relativePath = newrelativePath;
const id = asset.id;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册