From a229774915409b2a4ee2733c41b046e66264574c Mon Sep 17 00:00:00 2001 From: wuxiaodan Date: Fri, 24 Mar 2023 01:33:13 +0000 Subject: [PATCH] update distributedKVStorejstest/hap/src/main/js/test/KvManagerKVPromiseJsTest.js. Signed-off-by: wuxiaodan --- .../hap/src/main/js/test/KvManagerKVPromiseJsTest.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/distributeddatamgr/distributedKVStoretest/distributedKVStorejstest/hap/src/main/js/test/KvManagerKVPromiseJsTest.js b/distributeddatamgr/distributedKVStoretest/distributedKVStorejstest/hap/src/main/js/test/KvManagerKVPromiseJsTest.js index 5812ace58..3666d25a2 100644 --- a/distributeddatamgr/distributedKVStoretest/distributedKVStorejstest/hap/src/main/js/test/KvManagerKVPromiseJsTest.js +++ b/distributeddatamgr/distributedKVStoretest/distributedKVStorejstest/hap/src/main/js/test/KvManagerKVPromiseJsTest.js @@ -99,6 +99,7 @@ describe('KVManagerPromiseTest', function () { }); } catch (e) { console.error('SUB_DDM_DKV_KVMANAGER_GETKVSTORE_PROMISE_0100 getKVStore e ' + `, error code is ${e.code}, message is ${e.message}`); + expect(e.code == 401).assertTrue(); } done(); }) @@ -120,6 +121,7 @@ describe('KVManagerPromiseTest', function () { }); } catch (e) { console.error('SUB_DDM_DKV_KVMANAGER_GETKVSTORE_PROMISE_0200 getKVStore e ' + `, error code is ${e.code}, message is ${e.message}`); + expect(e.code == 401).assertTrue(); } done(); }) @@ -146,6 +148,7 @@ describe('KVManagerPromiseTest', function () { expect(null).assertFail(); }).catch((err) => { console.error('SUB_DDM_DKV_KVMANAGER_GETKVSTORE_PROMISE_0300 getKVStore err ' + `, error code is ${err.code}, message is ${err.message}`); + expect(err.code == 401).assertTrue(); }); done(); }) -- GitLab