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

!7143 【Distributeddatamgr】【master】修改/RdbstorePredicatesJsunit.test.js用例,用例优化

Merge pull request !7143 from yanglifeng/master
...@@ -2185,10 +2185,11 @@ describe('rdbPredicatesTest', function () { ...@@ -2185,10 +2185,11 @@ describe('rdbPredicatesTest', function () {
predicates.like("stringValue", "ABCDEFGHIJKLMN").indexedBy(["characterValue"]); predicates.like("stringValue", "ABCDEFGHIJKLMN").indexedBy(["characterValue"]);
let result = await rdbStore.query(predicates); let result = await rdbStore.query(predicates);
expect(3).assertEqual(result.rowCount); expect(3).assertEqual(result.rowCount);
}catch(err){ } catch (err) {
errInfo = err expect(err != undefined).assertTrue();
console.info(TAG + "testIndexedBy0001 err " + err);
errInfo = err;
} }
expect(errInfo.code).assertEqual("401")
done(); done();
console.info(TAG + "************* testIndexedBy0001 end *************"); console.info(TAG + "************* testIndexedBy0001 end *************");
}) })
...@@ -2206,10 +2207,11 @@ describe('rdbPredicatesTest', function () { ...@@ -2206,10 +2207,11 @@ describe('rdbPredicatesTest', function () {
predicates.like("stringValue", "ABCDEFGHIJKLMN").indexedBy(["characterValueX"]); predicates.like("stringValue", "ABCDEFGHIJKLMN").indexedBy(["characterValueX"]);
let result = await rdbStore.query(predicates); let result = await rdbStore.query(predicates);
expect(3).assertEqual(result.rowCount); expect(3).assertEqual(result.rowCount);
}catch(err){ } catch (err) {
errInfo = err expect(err != undefined).assertTrue();
console.info(TAG + "testIndexedBy0002 err " + err);
errInfo = err;
} }
expect(errInfo.code).assertEqual("401")
done(); done();
console.info(TAG + "************* testIndexedBy0002 end *************"); console.info(TAG + "************* testIndexedBy0002 end *************");
}) })
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册