提交 d95f0163 编写于 作者: W wangtiantian

IssueNo: #I51U5U:fix testcase

Description:fix testcase
Sig:SIG_ApplicaitonFramework
Feature or Bugfix:BugFix
Binary Source:No
Signed-off-by: Nwangtiantian <wangtiantian19@huawei.com>
上级 514212f7
...@@ -347,6 +347,7 @@ describe('ActsBmsJsTest', function () { ...@@ -347,6 +347,7 @@ describe('ActsBmsJsTest', function () {
* @tc.desc Test hasInstalled interface. * @tc.desc Test hasInstalled interface.
*/ */
it('hasInstalled_0400', 0, async function (done) { it('hasInstalled_0400', 0, async function (done) {
let flag = false;
pkg.hasInstalled({ pkg.hasInstalled({
bundleName: NUM_TWO, bundleName: NUM_TWO,
success: function success(data) { success: function success(data) {
...@@ -355,11 +356,15 @@ describe('ActsBmsJsTest', function () { ...@@ -355,11 +356,15 @@ describe('ActsBmsJsTest', function () {
}, },
fail: function fail(data, code) { fail: function fail(data, code) {
console.info('hasInstalled fail function in'); console.info('hasInstalled fail function in');
expect(flag).assertFalse();
flag = true;
expect(data).assertEqual(ERR_MERSSAGE); expect(data).assertEqual(ERR_MERSSAGE);
expect(code).assertEqual(ERR_CODE); expect(code).assertEqual(ERR_CODE);
}, },
complete: function complete() { complete: function complete() {
console.info('hasInstalled complete function in'); console.info('hasInstalled complete function in');
expect(flag).assertTrue();
flag = true;
} }
}); });
done(); done();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册