diff --git a/account/appaccount/actsaccountoperatetest/src/main/js/test/ChangeOnOff.js b/account/appaccount/actsaccountoperatetest/src/main/js/test/ChangeOnOff.js index 0fa5e8b4b10d96c6b02b23f46f693ac40b50e1a4..a5b5cf93c7853ea7a66e96e96833aefa1535ab29 100644 --- a/account/appaccount/actsaccountoperatetest/src/main/js/test/ChangeOnOff.js +++ b/account/appaccount/actsaccountoperatetest/src/main/js/test/ChangeOnOff.js @@ -17,7 +17,7 @@ import commonevent from '@ohos.commonEvent' import featureAbility from '@ohos.ability.featureAbility' import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' -const TIMEOUT = 5000; +const TIMEOUT = 2000; export default function ActsAccountOnOff() { describe('ActsAccountOnOff', async function () { diff --git a/account/appaccount/actsaccounttest/src/main/js/test/OnOff.js b/account/appaccount/actsaccounttest/src/main/js/test/OnOff.js index d49f77710170ac30b32447ff32b11e8e69a6343e..b04f0b29c2e2d5392bbae59a7418ef9895666150 100644 --- a/account/appaccount/actsaccounttest/src/main/js/test/OnOff.js +++ b/account/appaccount/actsaccounttest/src/main/js/test/OnOff.js @@ -17,7 +17,7 @@ import commonevent from '@ohos.commonEvent' import featureAbility from '@ohos.ability.featureAbility' import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' -const TIMEOUT = 5000; +const TIMEOUT = 2000; export default function ActsAccountChangeOnOff() { describe('ActsAccountChangeOnOff', async function () { diff --git a/account/appaccount/sceneProject/actsaccountsceneonoff/entry/src/main/js/default/pages/index/index.js b/account/appaccount/sceneProject/actsaccountsceneonoff/entry/src/main/js/default/pages/index/index.js index 47c8c50db0aaec97b0e9614c1935420bd5e752ef..669177e2bd13be5a2a2ab08a4042dfa694849e1e 100755 --- a/account/appaccount/sceneProject/actsaccountsceneonoff/entry/src/main/js/default/pages/index/index.js +++ b/account/appaccount/sceneProject/actsaccountsceneonoff/entry/src/main/js/default/pages/index/index.js @@ -35,10 +35,10 @@ injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') export default { data: { }, - onInit() { + onShow() { this.title = "scene on off"; }, - onShow() { + onInit() { console.debug("====>change on off scene start===="); var appAccountManager = account.createAppAccountManager(); var commonEventSubscribeInfo = { @@ -55,7 +55,7 @@ export default { console.debug("====>scene off finish===="); }); }); - featureAbility.terminateSelf() + // featureAbility.terminateSelf() } // Subscribe to the callback of account information changes, verify the received account information, and send