提交 c08c3855 编写于 作者: L lwx1121892

<medialibrary XTS 整改>

Signed-off-by: Nlwx1121892 <liuxueqi3@huawei.com>
上级 d76cde46
......@@ -272,7 +272,7 @@ describe('mediaLibraryTestCallBack.test.js', function () {
};
try {
media.getFileAssets(fetchOp, (err, fetchFileResult) => {
expect(fetchFileResult == undefined).assertTrue();
expect(err != undefined).assertTrue();
done();
});
} catch (error) {
......@@ -297,7 +297,7 @@ describe('mediaLibraryTestCallBack.test.js', function () {
};
try {
media.getFileAssets(fetchOp, (err, fetchFileResult) => {
expect(fetchFileResult == undefined).assertTrue();
expect(err != undefined).assertTrue();
done();
});
} catch (error) {
......@@ -328,7 +328,7 @@ describe('mediaLibraryTestCallBack.test.js', function () {
};
try {
media.getFileAssets(fetchOp, (err, fetchFileResult) => {
expect(fetchFileResult == undefined).assertTrue();
expect(err != undefined).assertTrue();
done();
});
} catch (error) {
......@@ -361,7 +361,7 @@ describe('mediaLibraryTestCallBack.test.js', function () {
};
try {
media.getFileAssets(fetchOp, (err, fetchFileResult) => {
expect(fetchFileResult == undefined).assertTrue();
expect(err != undefined).assertTrue();
done();
});
} catch (error) {
......
......@@ -284,10 +284,10 @@ describe('mediaLibraryTestPromise.test.js', function () {
selectionArgs: ['abc'],
};
try {
await media.getFileAssets(fetchOp);
console.info('MediaLibraryTest : getFileAssets 008 failed');
expect(false).assertTrue();
await media.getFileAssets(fetchOp).then((err, fetchFileResult) => {
expect(err != undefined).assertTrue();
done();
})
} catch (error) {
console.info(`MediaLibraryTest : getFileAssets 008 passed`);
expect(true).assertTrue();
......@@ -309,10 +309,10 @@ describe('mediaLibraryTestPromise.test.js', function () {
selectionArgs: ['abc', audioType.toString()],
};
try {
await media.getFileAssets(fetchOp);
console.info('MediaLibraryTest : getFileAssets 009 failed');
expect(false).assertTrue();
await media.getFileAssets(fetchOp).then((err, fetchFileResult) => {
expect(err != undefined).assertTrue();
done();
})
} catch (error) {
console.info('MediaLibraryTest : getFileAssets 009 passed');
expect(true).assertTrue();
......@@ -340,10 +340,10 @@ describe('mediaLibraryTestPromise.test.js', function () {
selectionArgs: ['abc', videoType.toString(), fileType.toString()],
};
try {
await media.getFileAssets(fetchOp);
console.info('MediaLibraryTest : getFileAssets 010 failed');
expect(false).assertTrue();
await media.getFileAssets(fetchOp).then((err, fetchFileResult) => {
expect(err != undefined).assertTrue();
done();
})
} catch (error) {
console.info('MediaLibraryTest : getFileAssets 010 passed');
expect(true).assertTrue();
......@@ -373,10 +373,14 @@ describe('mediaLibraryTestPromise.test.js', function () {
selectionArgs: ['abc', videoType.toString(), fileType.toString(), audioType.toString()],
};
try {
await media.getFileAssets(fetchOp);
console.info('MediaLibraryTest : getFileAssets 011 failed');
expect(false).assertTrue();
done();
// await media.getFileAssets(fetchOp);
// console.info('MediaLibraryTest : getFileAssets 011 failed');
// expect(false).assertTrue();
// done();
await media.getFileAssets(fetchOp).then((err, fetchFileResult) => {
expect(err != undefined).assertTrue();
done();
})
} catch (error) {
console.info('MediaLibraryTest : getFileAssets 011 passed');
expect(true).assertTrue();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册