diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/Test.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/Test.json index 97af5807eccc76c0513b5177053f2ed6d6ed6a1a..9a87ef1dea6914c5a83fbeb844b6f969bd9b6d4e 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/Test.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "120000", "package": "com.example.actsbmsallshortcutinfotest", "shell-timeout": "60000" }, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/src/main/js/test/ActsBmsAllShortcutInfoTest.test.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/src/main/js/test/ActsBmsAllShortcutInfoTest.test.js index 8ca34a45f1be1237803d97acb3b86351472448fa..2648fb69d9c391892269401c2f220367bb34b482 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/src/main/js/test/ActsBmsAllShortcutInfoTest.test.js +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsallshortcutinfotest/entry/src/main/js/test/ActsBmsAllShortcutInfoTest.test.js @@ -16,7 +16,11 @@ import bundle from '@ohos.bundle' import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from 'deccjsunit/index' +const TIMEOUT = 1000; +const NAMECOUNT = 10000; + describe('ActsBmsAllShortcutInfoTest', function () { + /* * @tc.number: bms_getAllShortcutInfo_0100 * @tc.name: test getAllShortcutInfo with promise @@ -33,7 +37,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { checkShortcutIsExist(data, 'id.third1', 'third1'); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0100==================end'); + }, TIMEOUT) }); + /* * @tc.number: bms_getAllShortcutInfo_0200 * @tc.name: test getAllShortcutInfo with callback @@ -48,7 +56,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { checkShortcutIsExist(data, 'id.third1', 'third1'); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0200==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_0300 * @tc.name: test getAllShortcutInfo with promise @@ -66,6 +78,9 @@ describe('ActsBmsAllShortcutInfoTest', function () { checkShortcutIsExist(data, 'id.third1', 'third1'); checkShortcutIsExist(data, 'id.third3', 'third3'); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0300==================end'); + }, TIMEOUT) }) /* @@ -84,7 +99,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { await uninstall(bundleName); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0400==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_0500 * @tc.name: test getAllShortcutInfo with promise @@ -96,7 +115,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(typeof data).assertEqual('object'); expect(data.length).assertEqual(0); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0500==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_0600 * @tc.name: test getAllShortcutInfo with callback @@ -110,7 +133,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0600==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_0700 * @tc.name: test getAllShortcutInfo with promise @@ -146,7 +173,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { } } done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0700==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_0800 * @tc.name: test getAllShortcutInfo with callback @@ -178,7 +209,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { await uninstall(bundleName); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0800==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_0900 * @tc.name: test getAllShortcutInfo with promise @@ -193,7 +228,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(typeof data).assertEqual('object'); expect(data.length).assertEqual(0); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_0900==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1000 * @tc.name: test getAllShortcutInfo with callback @@ -208,7 +247,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { await uninstall(bundleName); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1000==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1100 * @tc.name: test getAllShortcutInfo with promise @@ -222,7 +265,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(1); checkShortcutIsExist(data, 'id.system1', 'system1'); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1100==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1200 * @tc.name: test getAllShortcutInfo with callback @@ -237,7 +284,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { checkShortcutIsExist(data, 'id.system1', 'system1'); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1200==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1300 * @tc.name: test getAllShortcutInfo with promise @@ -251,7 +302,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(1); checkShortcutIsExist(data, 'id.vendor1', 'vendor1'); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1300==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1400 * @tc.name: test getAllShortcutInfo with callback @@ -266,7 +321,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { checkShortcutIsExist(data, 'id.vendor1', 'vendor1'); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1400==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1500 * @tc.name: test getAllShortcutInfo with promise @@ -287,7 +346,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { var info = await bundle.getAllShortcutInfo(bundleName); expect(info.length).assertEqual(0); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1500==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1600 * @tc.name: test getAllShortcutInfo with callback @@ -301,6 +364,9 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1600==================end'); + }, TIMEOUT) }) /* @@ -319,7 +385,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { checkShortcutIsExist(data, 'id.third4A', 'third4A'); checkShortcutIsExist(data, 'id.third4B', 'third4B'); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1700==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1800 * @tc.name: test getAllShortcutInfo with callback @@ -336,7 +406,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { await uninstall(bundleName); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1800==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_1900 * @tc.name: test getAllShortcutInfo with promise @@ -349,7 +423,11 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_1900==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getAllShortcutInfo_2000 * @tc.name: test getAllShortcutInfo with promise @@ -363,6 +441,9 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_2000==================end'); + }, TIMEOUT) }) /* @@ -373,13 +454,16 @@ describe('ActsBmsAllShortcutInfoTest', function () { it('bms_getAllShortcutInfo_2100', 0, async function (done) { console.info('=====================bms_getAllShortcutInfo_2100=================='); var bundleName = 'test'; - for(var i = 0; i < 10000; i++){ + for (var i = 0; i < NAMECOUNT; i++) { bundleName += 'test'; } var data = await bundle.getAllShortcutInfo(bundleName); expect(typeof data).assertEqual('object'); expect(data.length).assertEqual(0); done(); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_2100==================end'); + }, TIMEOUT) }) /* @@ -390,7 +474,7 @@ describe('ActsBmsAllShortcutInfoTest', function () { it('bms_getAllShortcutInfo_2200', 0, async function (done) { console.info('=====================bms_getAllShortcutInfo_2200=================='); var bundleName = 'test'; - for(var i = 0; i < 10000; i++){ + for (var i = 0; i < NAMECOUNT; i++) { bundleName += 'test'; } bundle.getAllShortcutInfo(bundleName, async (result, data) => { @@ -398,6 +482,9 @@ describe('ActsBmsAllShortcutInfoTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.info('=====================bms_getAllShortcutInfo_2200==================end'); + }, TIMEOUT) }) function checkShortcutInfo(dataInfo, name) { @@ -416,9 +503,9 @@ describe('ActsBmsAllShortcutInfoTest', function () { if (typeof dataInfo.wants != 'undefined' && Object.keys(dataInfo.wants).length != 0) { expect(dataInfo.wants.length).assertLarger(0); for (var j = 0; j < dataInfo.wants.length; j++) { - console.info('=============targetClass==============' + JSON.stringify(dataInfo.wants[j].targetClass)); + console.info('========targetClass=========' + JSON.stringify(dataInfo.wants[j].targetClass)); expect(dataInfo.wants[j].targetClass).assertEqual('com.example.' + name + '.MainAbility'); - console.info('=============targetBundle==============' + JSON.stringify(dataInfo.wants[j].targetBundle)); + console.info('========targetBundle=========' + JSON.stringify(dataInfo.wants[j].targetBundle)); expect(dataInfo.wants[j].targetBundle).assertEqual('com.example.' + name); } } @@ -426,7 +513,7 @@ describe('ActsBmsAllShortcutInfoTest', function () { async function install(bundlePath) { let result = await bundle.getBundleInstaller(); - await result.install(bundlePath, { + result.install(bundlePath, { param: { userId: 0, installFlag: 1, @@ -441,7 +528,7 @@ describe('ActsBmsAllShortcutInfoTest', function () { } async function uninstall(bundleName) { let result = await bundle.getBundleInstaller(); - await result.uninstall(bundleName, { + result.uninstall(bundleName, { param: { userId: 0, installFlag: 1, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/Test.json b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/Test.json index 7088eed4cb5fb9c8dff435f7bd64bd49559b4a27..eddc706a3745bb94c92216fa04df2d61a4b02e71 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/Test.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsbmscheckpermissiontest", "shell-timeout": "60000" }, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/config.json b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/config.json index cc30895977c2c079594f131d31ff516da1984371..98d7fe050fa56acfd528e3458aae37d9687cf8ca 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/config.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/config.json @@ -76,7 +76,7 @@ "reason": "Need open camera", "usedScene": { "ability": [ - "com.example.permissionchange.MainAbility" + "com.example.actsbmscheckpermissiontest.MainAbility" ], "when": "always" } @@ -86,7 +86,7 @@ "reason": "Need PERMISSION_A", "usedScene": { "ability": [ - "com.example.permissionchange.MainAbility" + "com.example.actsbmscheckpermissiontest.MainAbility" ], "when": "always" } diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/js/test/ActsBmsCheckPermissionTest.test.js b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/js/test/ActsBmsCheckPermissionTest.test.js index 9cab7e56d25a189bf42de5af959c1e156537ce5f..a6107f3e07fbc500a50fe788c6469e070470ffb7 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/js/test/ActsBmsCheckPermissionTest.test.js +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmscheckpermissiontest/entry/src/main/js/test/ActsBmsCheckPermissionTest.test.js @@ -19,8 +19,11 @@ import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from const BUNDLE_NAME = 'com.example.actsbmscheckpermissiontest'; const PERMISSION_ONE = 'com.permission.CAMERA'; const PERMISSION_TWO = 'com.permission.PERMISSION_A'; +const TIMEOUT = 1000; +const NAMECOUNT = 10000; describe('ActsBmsCheckPermissionTest', function () { + /* * @tc.number: bms_checkPermission_0100 * @tc.name: check whether the permission is granted @@ -31,7 +34,11 @@ describe('ActsBmsCheckPermissionTest', function () { var data = await bundle.checkPermission(BUNDLE_NAME, PERMISSION_TWO) expect(data).assertEqual(0); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_0100==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0200 * @tc.name: check whether the permission is granted @@ -44,7 +51,11 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(0); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_0200==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0300 * @tc.name: check whether the permission is granted @@ -56,7 +67,11 @@ describe('ActsBmsCheckPermissionTest', function () { var data = await bundle.checkPermission('', PERMISSION_ONE) expect(data).assertEqual(-1); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_0300==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0400 * @tc.name: check whether the permission is granted @@ -70,7 +85,11 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(-1); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_0400==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0500 * @tc.name: check whether the permission is granted @@ -82,7 +101,11 @@ describe('ActsBmsCheckPermissionTest', function () { var data = await bundle.checkPermission(BUNDLE_NAME, '') expect(data).assertEqual(-1); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_0500==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0600 * @tc.name: check whether the permission is granted @@ -96,7 +119,11 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(-1); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_0600==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0700 * @tc.name: check whether the permission is granted @@ -108,6 +135,9 @@ describe('ActsBmsCheckPermissionTest', function () { var data = await bundle.checkPermission(BUNDLE_NAME, '@\n,. 。测试@abc1^%12345') expect(data).assertEqual(-1); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_0700==================end'); + }, TIMEOUT) }) /* @@ -123,7 +153,11 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(-1); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_0800==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_0900 * @tc.name: check whether the permission is granted @@ -135,7 +169,11 @@ describe('ActsBmsCheckPermissionTest', function () { var data = await bundle.checkPermission('@\n,. 。测试@abc1^%12345', PERMISSION_ONE) expect(data).assertEqual(-1); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_0900==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_1000 * @tc.name: check whether the permission is granted @@ -149,7 +187,11 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(-1); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_1000==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_1100 * @tc.name: check whether the permission is granted @@ -159,12 +201,15 @@ describe('ActsBmsCheckPermissionTest', function () { it('bms_checkPermission_1100', 0, async function (done) { console.info('=====================bms_checkPermission_1100=================='); var permissionName = 'test'; - for (var i = 0; i < 10000; i++) { + for (var i = 0; i < NAMECOUNT; i++) { permissionName += 'test'; } var data = await bundle.checkPermission(BUNDLE_NAME, permissionName) expect(data).assertEqual(-1); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_1100==================end'); + }, TIMEOUT) }) /* @@ -176,7 +221,7 @@ describe('ActsBmsCheckPermissionTest', function () { it('bms_checkPermission_1200', 0, async function (done) { console.info('=====================bms_checkPermission_1200=================='); var permissionName = 'test'; - for (var i = 0; i < 10000; i++) { + for (var i = 0; i < NAMECOUNT; i++) { permissionName += 'test'; } await bundle.checkPermission(BUNDLE_NAME, permissionName, (err, data) => { @@ -184,7 +229,11 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(-1); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_1200==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_1300 * @tc.name: check whether the permission is granted @@ -194,13 +243,17 @@ describe('ActsBmsCheckPermissionTest', function () { it('bms_checkPermission_1300', 0, async function (done) { console.info('=====================bms_checkPermission_1300=================='); var bundleName = 'test'; - for (var i = 0; i < 10000; i++) { + for (var i = 0; i < NAMECOUNT; i++) { bundleName += 'test'; } var data = await bundle.checkPermission(bundleName, PERMISSION_ONE) expect(data).assertEqual(-1); done(); + setTimeout(function () { + console.info('=====================bms_checkPermission_1300==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_checkPermission_1400 * @tc.name: check whether the permission is granted @@ -210,7 +263,7 @@ describe('ActsBmsCheckPermissionTest', function () { it('bms_checkPermission_1400', 0, async function (done) { console.info('=====================bms_checkPermission_1400=================='); var bundleName = 'test'; - for (var i = 0; i < 10000; i++) { + for (var i = 0; i < NAMECOUNT; i++) { bundleName += 'test'; } await bundle.checkPermission(bundleName, PERMISSION_ONE, (err, data) => { @@ -218,5 +271,8 @@ describe('ActsBmsCheckPermissionTest', function () { expect(data).assertEqual(-1); done(); }) + setTimeout(function () { + console.info('=====================bms_checkPermission_1400==================end'); + }, TIMEOUT) }) }) \ No newline at end of file diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/Test.json b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/Test.json index 11364f30747746383654bd99ef9460c09967fe4a..a211f78331da28a43d03151a6ab5ec7eb6107ac4 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/Test.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/Test.json @@ -2,9 +2,9 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsbmshapmoduletest", - "shell-timeout": "300000" + "shell-timeout": "60000" }, "kits": [ { @@ -24,7 +24,7 @@ { "type": "PushKit", "push": [ - "bmsMainAbilityFirstScene.hap.hap->/data/test/bmsMainAbilityFirstScene.hap", + "bmsMainAbilityFirstScene.hap->/data/test/bmsMainAbilityFirstScene.hap", "bmsMainAbilitySecondScene.hap->/data/test/bmsMainAbilitySecondScene.hap", "bmsThirdBundleTest2.hap->/data/test/bmsThirdBundleTest2.hap" ] diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/src/main/js/test/ActsBmsHapModuleTest.test.js b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/src/main/js/test/ActsBmsHapModuleTest.test.js index 0f41354e27b2925da3aa86533b817a6118b41a6e..6ad9fe60425ace51abe5f821bd27ae1cc0a55206 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/src/main/js/test/ActsBmsHapModuleTest.test.js +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmshapmoduletest/entry/src/main/js/test/ActsBmsHapModuleTest.test.js @@ -14,9 +14,12 @@ */ import bundle from '@ohos.bundle' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from 'deccjsunit/index' + +const TIMEOUT = 1000; describe('ActsBmsHapModuleTest', function () { + /* * @tc.number: bms_getHapModuleInfo_0100 * @tc.name: get hapModuleInfo from one app by getBundleInfo @@ -26,8 +29,8 @@ describe('ActsBmsHapModuleTest', function () { console.debug('===========begin bms_getHapModuleInfo_0100===========') await install(['/data/test/bmsMainAbilityFirstScene.hap']); let bundleName = 'com.example.bmsmainabilityfirstscene'; + let ret = false bundle.getBundleInfo(bundleName, 1, callback); - function callback(err, data) { console.debug('=======get bundle========' + JSON.stringify(data)); let hapModuleInfo = data.hapModuleInfo[0]; @@ -36,11 +39,14 @@ describe('ActsBmsHapModuleTest', function () { expect(hapModuleInfo.moduleName).assertEqual('entry'); expect(hapModuleInfo.mainAbilityName).assertEqual('com.example.bmsmainabilityfirstscene.MainAbility'); checkHapModuleInfo(hapModuleInfo); + ret = true; done(); } + setTimeout(function () { + expect(ret).assertTrue(); + }, TIMEOUT); }); - /* * @tc.number: bms_getHapModuleInfo_0200 * @tc.name: get hapModuleInfo from two modules by getBundleInfo @@ -49,6 +55,7 @@ describe('ActsBmsHapModuleTest', function () { it('bms_getHapModuleInfo_0200', 0, async function (done) { console.debug('===========begin bms_getHapModuleInfo_0200===========') await install(['/data/test/bmsMainAbilitySecondScene.hap']); + let ret = false let bundleName = 'com.example.bmsmainabilityfirstscene'; let firstMainAbility = 'com.example.bmsmainabilityfirstscene.MainAbility'; let secondMainAbility = 'com.example.bmsmainabilitysecondscene.MainAbility'; @@ -56,7 +63,7 @@ describe('ActsBmsHapModuleTest', function () { bundle.getBundleInfo(bundleName, 1, async (err, data) => { console.debug('=======hapModule length========' + data.hapModuleInfo.length); expect(data.hapModuleInfo.length).assertEqual(2); - for (let i = 0, len = data.hapModuleInfo.length;i < len; i++) { + for (let i = 0, len = data.hapModuleInfo.length; i < len; i++) { console.debug('=======get hapModule========' + JSON.stringify(data.hapModuleInfo[i])) console.debug('=======get hapModule mainAbilityName========' + data.hapModuleInfo[i].mainAbilityName); checkHapModuleInfo(data.hapModuleInfo[i]); @@ -67,8 +74,12 @@ describe('ActsBmsHapModuleTest', function () { expect(result.get(firstMainAbility).moduleName).assertEqual('entry'); expect(result.get(secondMainAbility).moduleName).assertEqual('bmsmainabilitysecondscene'); await uninstall(bundleName); + ret = true; done(); }) + setTimeout(function () { + expect(ret).assertTrue(); + }, TIMEOUT); }) /* @@ -80,6 +91,7 @@ describe('ActsBmsHapModuleTest', function () { console.debug('===========begin bms_getHapModuleInfo_0300===========') await install(['/data/test/bmsThirdBundleTest2.hap']); let bundleName = 'com.example.third2'; + let ret = false; bundle.getBundleInfo(bundleName, 1).then(async (data) => { console.debug('=======get hapModule========' + JSON.stringify(data)) expect(data.hapModuleInfo.length).assertEqual(1); @@ -88,8 +100,12 @@ describe('ActsBmsHapModuleTest', function () { expect(data.hapModuleInfo[0].moduleName).assertEqual('entry'); checkHapModuleInfo(data.hapModuleInfo[0]); await uninstall(bundleName); + ret = true; done(); }) + setTimeout(function () { + expect(ret).assertTrue(); + }, TIMEOUT); }) function checkHapModuleInfo(dataInfo) { @@ -111,17 +127,16 @@ describe('ActsBmsHapModuleTest', function () { expect(typeof dataInfo.installationFree).assertEqual('boolean'); } - async function install(bundlePath) - { + async function install(bundlePath) { var installer = await bundle.getBundleInstaller(); - await installer.install(bundlePath, { + console.log('========install========' + typeof installer); + installer.install(bundlePath, { param: { userId: 0, installFlag: 1, isKeepData: false } }, onReceiveInstallEvent); - function onReceiveInstallEvent(err, data) { console.info('========install Finish========'); expect(typeof err).assertEqual('object'); @@ -132,10 +147,9 @@ describe('ActsBmsHapModuleTest', function () { } } - async function uninstall(bundleName) - { + async function uninstall(bundleName) { var installer = await bundle.getBundleInstaller(); - await installer.uninstall(bundleName, { + installer.uninstall(bundleName, { param: { userId: 0, installFlag: 1, @@ -152,5 +166,4 @@ describe('ActsBmsHapModuleTest', function () { expect(data.statusMessage).assertEqual('SUCCESS'); } } - }) \ No newline at end of file diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/Test.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/Test.json index 3d24f119274133928b83959fd616879cddd69560..a3f53e8870b5b6c7ddc0e87fd7de76a8739d7cec 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/Test.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsbmsjstest", "shell-timeout": "60000" }, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/src/main/js/test/ActsBmsJsTest.test.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/src/main/js/test/ActsBmsJsTest.test.js index c59363cd22e484de88f384a1d56113bbfe3f7fe7..6b815621d787533490119cec6b45138cd4496cfb 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/src/main/js/test/ActsBmsJsTest.test.js +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsjstest/entry/src/main/js/test/ActsBmsJsTest.test.js @@ -13,9 +13,12 @@ * limitations under the License. */ import bundle from '@ohos.bundle' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from 'deccjsunit/index' + +const TIMEOUT = 3000; describe('ActsBmsJsTest', function () { + /* * @tc.number: bms_getJsAbility_0100 * @tc.name: test the multi js ability @@ -27,13 +30,16 @@ describe('ActsBmsJsTest', function () { let bundleName = 'com.example.third2'; let abilityName = 'com.example.third2.MainAbility'; await install(['/data/test/bmsThirdBundleTest2.hap']); - bundle.getBundleInfo(bundleName,1).then((data)=>{ - expect(data.abilityInfo.length).assertEqual(1); - checkIsExist(abilityName, data); - uninstall(bundleName); - done(); - }); + let data = await bundle.getBundleInfo(bundleName, 1); + expect(data.abilityInfo.length).assertEqual(1); + checkIsExist(abilityName, data); + await uninstall(bundleName); + done(); + setTimeout(function () { + console.info('=====================bms_getJsAbility_0100==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getJsAbility_0200 * @tc.name: test the multi js ability @@ -46,15 +52,18 @@ describe('ActsBmsJsTest', function () { let abilityName1 = 'com.example.third5.AMainAbility'; let abilityName2 = 'com.example.third5.BMainAbility'; await install(['/data/test/bmsThirdBundleTest5.hap']); - bundle.getBundleInfo(bundleName,1).then((data)=>{ - console.debug('==========bundleInfo==========' + JSON.stringify(data)) - expect(data.abilityInfo.length).assertLarger(1); - checkIsExist(abilityName1, data); - checkIsExist(abilityName2, data); - uninstall(bundleName); - done(); - }); + let data = await bundle.getBundleInfo(bundleName, 1) + console.debug('==========bundleInfo==========' + JSON.stringify(data)) + expect(data.abilityInfo.length).assertLarger(1); + checkIsExist(abilityName1, data); + checkIsExist(abilityName2, data); + await uninstall(bundleName); + done(); + setTimeout(function () { + console.info('=====================bms_getJsAbility_0200==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getJsAbility_0300 * @tc.name: test the multi js ability @@ -66,17 +75,18 @@ describe('ActsBmsJsTest', function () { let bundleName = 'com.example.js'; let abilityName = 'com.example.js.MainAbility'; await install(['/data/test/bmsThirdBundleJs.hap']); - bundle.getBundleInfo(bundleName,1).then((data)=>{ - expect(data.abilityInfo.length).assertEqual(1); - checkIsExist(abilityName, data); - uninstall(bundleName); - done(); - }); + let data = await bundle.getBundleInfo(bundleName, 1); + expect(data.abilityInfo.length).assertEqual(1); + checkIsExist(abilityName, data); + await uninstall(bundleName); + done(); + setTimeout(function () { + console.info('=====================bms_getJsAbility_0300==================end'); + }, TIMEOUT) }) - async function install(bundlePath) - { + async function install(bundlePath) { var installer = await bundle.getBundleInstaller(); - await installer.install(bundlePath, { + installer.install(bundlePath, { param: { userId: 0, installFlag: 1, @@ -96,7 +106,7 @@ describe('ActsBmsJsTest', function () { async function uninstall(bundleName) { var installer = await bundle.getBundleInstaller(); - await installer.uninstall(bundleName, { + installer.uninstall(bundleName, { param: { userId: 0, installFlag: 1, @@ -118,8 +128,7 @@ describe('ActsBmsJsTest', function () { console.debug('==========bundleInfo==========' + JSON.stringify(data)) console.debug('==========AbilityInfo===========' + JSON.stringify(data.abilityInfo)) let abilityNames = new Map(); - for (var i = 0; i < data.abilityInfo.length; i++) - { + for (var i = 0; i < data.abilityInfo.length; i++) { console.debug('==========abilityName==========' + data.abilityInfo[i].name); abilityNames.set(data.abilityInfo[i].name, data.abilityInfo[i]); } diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/Test.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/Test.json index 5391f738da26c068b3f72033e438a2aa2db9ace7..fe85625f6d78d97c31cb21a80bf6323db0476437 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/Test.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsbmsmetadatatest", "shell-timeout": "60000" }, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/src/main/js/test/ActsBmsMetaDataTest.test.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/src/main/js/test/ActsBmsMetaDataTest.test.js index 8621a13a96543c6c82ec911717f9490abcbd6ebe..7e29d696cfe358f952fa947e6fe89104caf0c19a 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/src/main/js/test/ActsBmsMetaDataTest.test.js +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsmetadatatest/entry/src/main/js/test/ActsBmsMetaDataTest.test.js @@ -16,7 +16,10 @@ import bundle from '@ohos.bundle' import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from 'deccjsunit/index' +const TIMEOUT = 1000; + describe('ActsBmsMetaDataTest', function () { + /* * @tc.number: bms_getMetaData_0100 * @tc.name: test to get meta data for an application. @@ -51,7 +54,11 @@ describe('ActsBmsMetaDataTest', function () { }, 0, 0) checkMetaData(datainfo.metaData); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0100===========') + }, TIMEOUT); }) + /* * @tc.number: bms_getMetaData_0200 * @tc.name: test to get meta data for an update application. @@ -73,7 +80,11 @@ describe('ActsBmsMetaDataTest', function () { }, 0, 0) checkMetaData(datainfo.metaData); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0200===========') + }, TIMEOUT); }) + /* * @tc.number: bms_getMetaData_0300 * @tc.name: test to get meta data for an uninstalled application. @@ -97,7 +108,11 @@ describe('ActsBmsMetaDataTest', function () { console.info('==========abilityInfo is ==========' + JSON.stringify(datainfo)); checkMetaDataNoExit(datainfo.metaData); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0300===========') + }, TIMEOUT); }) + /* * @tc.number: bms_getMetaData_0400 * @tc.name: test to get meta data for an application. @@ -132,9 +147,13 @@ describe('ActsBmsMetaDataTest', function () { }, 0, 0) console.info('==========abilityInfo is ==========' + JSON.stringify(datainfo2)); checkMetaData(datainfo2.metaData); - uninstall('com.example.third5'); + await uninstall('com.example.third5'); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0400===========') + }, TIMEOUT); }) + /* * @tc.number: bms_getMetaData_0500 * @tc.name: test to get meta data for an application that does not exist. @@ -157,7 +176,11 @@ describe('ActsBmsMetaDataTest', function () { console.info('==========abilityInfo is ==========' + JSON.stringify(datainfo)); checkMetaDataNoExit(datainfo.metaData); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0500===========') + }, TIMEOUT); }) + /* * @tc.number: bms_getMetaData_0600 * @tc.name: test to get meta data for a system application. @@ -178,7 +201,11 @@ describe('ActsBmsMetaDataTest', function () { }, 0, 0) checkMetaData(datainfo.metaData); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0600===========') + }, TIMEOUT); }) + /* * @tc.number: bms_getMetaData_0700 * @tc.name: test to get meta data for a vendor application. @@ -199,6 +226,9 @@ describe('ActsBmsMetaDataTest', function () { }, 0, 0) checkMetaData(datainfo.metaData); done(); + setTimeout(function () { + console.debug('============bms_getMetaData_0700===========') + }, TIMEOUT); }) function checkMetaData(data) { @@ -254,7 +284,7 @@ describe('ActsBmsMetaDataTest', function () { } async function install(bundlePath) { var installer = await bundle.getBundleInstaller(); - await installer.install(bundlePath, { + installer.install(bundlePath, { param: { userId: 0, installFlag: 1, @@ -273,7 +303,7 @@ describe('ActsBmsMetaDataTest', function () { async function uninstall(bundleName) { var installer = await bundle.getBundleInstaller(); - await installer.uninstall(bundleName, { + installer.uninstall(bundleName, { param: { userId: 0, installFlag: 1, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/Test.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/Test.json index 86f8de9b48e0817569e96b8842be455c3c73b7f0..7517fc32009a13e9ab5c161eb824cb3d08999096 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/Test.json +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "120000", "package": "com.example.actsbmsmoduleusagerecordtest", "shell-timeout": "60000" }, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/src/main/js/test/ActsBmsModuleUsageRecordTest.test.js b/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/src/main/js/test/ActsBmsModuleUsageRecordTest.test.js index 1413a9f2c48a00b81b19735e99b088c8db5fc9b6..6e6a6f39cc61444114fab7cb550531f8af414f3c 100644 --- a/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/src/main/js/test/ActsBmsModuleUsageRecordTest.test.js +++ b/appexecfwk/bundle_standard/bundlemanager/actsbmsmoduleusagerecordtest/entry/src/main/js/test/ActsBmsModuleUsageRecordTest.test.js @@ -18,32 +18,25 @@ import featureAbility from '@ohos.ability.featureability' import commonEvent from '@ohos.commonevent' const START_ABILITY_TIMEOUT = 5000; -const MIN_NUM = 2; -const MAX_NUM = 10; +const NUM_TWO = 2; +const NUM_TEN = 10; const INVALID_NUM = -1; -var SubscriberInfo_bms_getModuleUsageRecordTest_0100 = { +const TIMEOUT = 1000; +const EVENTTIMEOUT = 2000; + +var subscriberInfoGetModuleUsageRecordTest_0100 = { events: ['ACTS_Third1_Publish_CommonEvent'], }; describe('ActsBmsModuleUsageRecordTest', function () { beforeAll(async (done) => { console.debug('=======before all install========'); - bundle.getBundleInstaller().then((data) => { - data.install(['/data/test/bmsThirdBundleTest1.hap'], { - param: { - userId: 0, - installFlag: 1, - isKeepData: false - } - }, onReceiveinstallEvent); - }) - function onReceiveinstallEvent(err, data) { - console.info('========install finish========' + JSON.stringify(err)); - console.info('========install finish========' + JSON.stringify(data)); - console.info('========install finish========' + data.status); - console.info('========install finish========' + data.statusMessage); - done() - } + await install(['/data/test/bmsThirdBundleTest1.hap']) + done(); + setTimeout(function () { + console.debug('=======before all install finish========'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0100 * @tc.name: getModuleUsageRecord(maxNum) @@ -59,17 +52,17 @@ describe('ActsBmsModuleUsageRecordTest', function () { clearTimeout(id); expect(data.event).assertEqual('ACTS_Third1_Publish_CommonEvent'); console.debug('====>Subscribe CallBack data:====>' + JSON.stringify(data)); - let records = await bundle.getModuleUsageRecords(MIN_NUM); + let records = await bundle.getModuleUsageRecords(NUM_TWO); checkModuleUsageRecord(records, 'bms_getModuleUsageRecordTest_0100'); var result = checkIsExist(records, bundleName); expect(result).assertEqual(true); commonEvent.unsubscribe(Subscriber, UnSubscribeCallback); done(); } - await commonEvent.createSubscriber(SubscriberInfo_bms_getModuleUsageRecordTest_0100).then(async (data) => { + commonEvent.createSubscriber(subscriberInfoGetModuleUsageRecordTest_0100).then((data) => { console.debug('====>Create Subscriber====>'); Subscriber = data; - await commonEvent.subscribe(Subscriber, SubscribeCallBack); + commonEvent.subscribe(Subscriber, SubscribeCallBack); }) function UnSubscribeCallback() { console.debug('====>UnSubscribe CallBack====>'); @@ -93,7 +86,11 @@ describe('ActsBmsModuleUsageRecordTest', function () { } ) expect(result).assertEqual(0); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0100==================end'); + }, EVENTTIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0200 * @tc.name: getModuleUsageRecord(maxNum) @@ -102,14 +99,18 @@ describe('ActsBmsModuleUsageRecordTest', function () { it('bms_getModuleUsageRecordTest_0200', 0, async function (done) { console.debug('=====================bms_getModuleUsageRecordTest_0200=================='); var bundleName = 'com.example.third1'; - bundle.getModuleUsageRecords(MIN_NUM, (err, data) => { + bundle.getModuleUsageRecords(NUM_TWO, (err, data) => { expect(err.code).assertEqual(0); checkModuleUsageRecord(data, 'bms_getModuleUsageRecordTest_0200'); var result = checkIsExist(data, bundleName); expect(result).assertEqual(true); done(); }); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0200==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0300 * @tc.name: getModuleUsageRecord(maxNum) @@ -118,14 +119,18 @@ describe('ActsBmsModuleUsageRecordTest', function () { it('bms_getModuleUsageRecordTest_0300', 0, async function (done) { console.debug('=====================bms_getModuleUsageRecordTest_0300=================='); var bundleName = 'com.example.third1'; - bundle.getModuleUsageRecords(MAX_NUM, (err, data) => { + bundle.getModuleUsageRecords(NUM_TEN, (err, data) => { expect(err.code).assertEqual(0); checkModuleUsageRecord(data, 'bms_getModuleUsageRecordTest_0300'); var result = checkIsExist(data, bundleName); expect(result).assertEqual(true); done(); }); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0300==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0400 * @tc.name: getModuleUsageRecord(maxNum) @@ -134,12 +139,16 @@ describe('ActsBmsModuleUsageRecordTest', function () { it('bms_getModuleUsageRecordTest_0400', 0, async function (done) { console.debug('=====================bms_getModuleUsageRecordTest_0400=================='); var bundleName = 'com.example.third1'; - var records = await bundle.getModuleUsageRecords(MAX_NUM); + var records = await bundle.getModuleUsageRecords(NUM_TEN); checkModuleUsageRecord(records, 'bms_getModuleUsageRecordTest_0400'); var result = checkIsExist(records, bundleName); expect(result).assertEqual(true); done(); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0400==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0500 * @tc.name: getModuleUsageRecord(maxNum) by promise @@ -151,12 +160,16 @@ describe('ActsBmsModuleUsageRecordTest', function () { var bundleName = 'com.example.third1' await uninstall(bundleName); console.debug('===================uninstall third1===================='); - var records = await bundle.getModuleUsageRecords(MAX_NUM) + var records = await bundle.getModuleUsageRecords(NUM_TEN) checkModuleUsageRecord(records, 'bms_getModuleUsageRecordTest_0500'); var result = checkIsExist(records, bundleName); expect(result).assertEqual(false); done(); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0500==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0600 * @tc.name: getModuleUsageRecord(maxNum,callback: AsyncCallback>) @@ -166,14 +179,18 @@ describe('ActsBmsModuleUsageRecordTest', function () { it('bms_getModuleUsageRecordTest_0600', 0, async function (done) { console.debug('=====================bms_getModuleUsageRecordTest_0600=================='); var bundleName = 'com.example.third1' - await bundle.getModuleUsageRecords(MAX_NUM, (err, data) => { + await bundle.getModuleUsageRecords(NUM_TEN, (err, data) => { expect(err.code).assertEqual(0); checkModuleUsageRecord(data, 'bms_getModuleUsageRecordTest_0600'); var result = checkIsExist(data, bundleName); expect(result).assertEqual(false); done(); }); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0600==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0700 * @tc.name: getModuleUsageRecord(maxNum, callback: AsyncCallback>) @@ -187,7 +204,11 @@ describe('ActsBmsModuleUsageRecordTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0700==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0800 * @tc.name: getModuleUsageRecord(maxNum) by promise @@ -198,7 +219,11 @@ describe('ActsBmsModuleUsageRecordTest', function () { var data = await bundle.getModuleUsageRecords(INVALID_NUM); expect(data.length).assertEqual(0); done(); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0800==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_0900 * @tc.name: getModuleUsageRecord(maxNum, callback: AsyncCallback>) @@ -212,7 +237,11 @@ describe('ActsBmsModuleUsageRecordTest', function () { expect(data.length).assertEqual(0); done(); }); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_0900==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_1000 * @tc.name: getModuleUsageRecord(maxNum, callback: AsyncCallback>) @@ -223,7 +252,11 @@ describe('ActsBmsModuleUsageRecordTest', function () { var data = await bundle.getModuleUsageRecords(0); expect(data.length).assertEqual(0); done(); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_1000==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_1100 * @tc.name: getModuleUsageRecord(maxNum) by promise @@ -236,12 +269,16 @@ describe('ActsBmsModuleUsageRecordTest', function () { var bundlePath = ['/data/test/bmsThirdBundleTest1.hap'] await install(bundlePath); console.debug('===================install third1===================='); - var records = await bundle.getModuleUsageRecords(MAX_NUM) + var records = await bundle.getModuleUsageRecords(NUM_TEN) checkModuleUsageRecord(records, 'bms_getModuleUsageRecordTest_1100'); var result = checkIsExist(records, bundleName); expect(result).assertEqual(true); done(); + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_1100==================end'); + }, TIMEOUT) }) + /* * @tc.number: bms_getModuleUsageRecordTest_1200 * @tc.name: getModuleUsageRecord(maxNum, callback: AsyncCallback>) @@ -251,13 +288,16 @@ describe('ActsBmsModuleUsageRecordTest', function () { it('bms_getModuleUsageRecordTest_1200', 0, async function (done) { console.debug('=====================bms_getModuleUsageRecordTest_1200=================='); var bundleName = 'com.example.third1' - await bundle.getModuleUsageRecords(MAX_NUM, (err, data) => { + await bundle.getModuleUsageRecords(NUM_TEN, (err, data) => { expect(err.code).assertEqual(0); checkModuleUsageRecord(data, 'bms_getModuleUsageRecordTest_1200'); var result = checkIsExist(data, bundleName); expect(result).assertEqual(true); done(); }) + setTimeout(function () { + console.debug('=====================bms_getModuleUsageRecordTest_1200==================end'); + }, TIMEOUT) }) function checkModuleUsageRecord(data, caseName) { @@ -310,7 +350,7 @@ describe('ActsBmsModuleUsageRecordTest', function () { } async function install(bundlePath) { var installer = await bundle.getBundleInstaller(); - await installer.install(bundlePath, { + installer.install(bundlePath, { param: { userId: 0, installFlag: 1, @@ -329,7 +369,7 @@ describe('ActsBmsModuleUsageRecordTest', function () { } async function uninstall(bundleName) { var installer = await bundle.getBundleInstaller(); - await installer.uninstall(bundleName, { + installer.uninstall(bundleName, { param: { userId: 0, installFlag: 1, diff --git a/appexecfwk/bundle_standard/bundlemanager/actsbundlemanagertest/entry/package.json b/appexecfwk/bundle_standard/bundlemanager/actsbundlemanagertest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/actsbundlemanagertest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/src/main/js/default2/app.js b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfifthscene/src/main/js/default2/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstscene/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstscene/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstsceneupdate/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstsceneupdate/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstsceneupdate/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstsceneupdate/src/main/js/default/app.js b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfirstsceneupdate/src/main/js/default/app.js old mode 100755 new mode 100644 diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfourthscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfourthscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosfourthscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosjsscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosjsscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosjsscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosscenesystem/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosscenesystem/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosscenesystem/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosscenevendor/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosscenevendor/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosscenevendor/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfossecondscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfossecondscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfossecondscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosthirdscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosthirdscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsgetinfosthirdscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsmainabilityfirstscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsmainabilityfirstscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsmainabilityfirstscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsmainabilitysecondscene/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsmainabilitysecondscene/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsmainabilitysecondscene/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneeight/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneeight/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneeight/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenefive/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenefive/package.json new file mode 100644 index 0000000000000000000000000000000000000000..0967ef424bce6791893e9a57bb952f80fd536e93 --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenefive/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenefour/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenefour/package.json new file mode 100644 index 0000000000000000000000000000000000000000..0967ef424bce6791893e9a57bb952f80fd536e93 --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenefour/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenenine/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenenine/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenenine/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneone/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneone/package.json new file mode 100644 index 0000000000000000000000000000000000000000..0967ef424bce6791893e9a57bb952f80fd536e93 --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneone/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneseven/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneseven/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmssceneseven/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenesix/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenesix/package.json new file mode 100644 index 0000000000000000000000000000000000000000..0967ef424bce6791893e9a57bb952f80fd536e93 --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenesix/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenethree/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenethree/package.json new file mode 100644 index 0000000000000000000000000000000000000000..0967ef424bce6791893e9a57bb952f80fd536e93 --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenethree/package.json @@ -0,0 +1 @@ +{} diff --git a/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenetwo/package.json b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenetwo/package.json new file mode 100644 index 0000000000000000000000000000000000000000..0967ef424bce6791893e9a57bb952f80fd536e93 --- /dev/null +++ b/appexecfwk/bundle_standard/bundlemanager/sceneProject/bmsscenetwo/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/actsansnotificationcancel/Test.json b/notification/ans_standard/actsansnotificationcancel/Test.json index 55139af73f1255634a8ab837ffd7245c0d4c875b..1a5ddb048da74ec2925da50e274b1a813935fa9d 100644 --- a/notification/ans_standard/actsansnotificationcancel/Test.json +++ b/notification/ans_standard/actsansnotificationcancel/Test.json @@ -2,9 +2,9 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "21600000", "package": "com.example.actsansnotificationcancel", - "shell-timeout": "60000" + "shell-timeout": "21600000" }, "kits": [ { diff --git a/notification/ans_standard/actsansnotificationcancel/entry/package.json b/notification/ans_standard/actsansnotificationcancel/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/actsansnotificationcancel/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/actsansnotificationremove/Test.json b/notification/ans_standard/actsansnotificationremove/Test.json index 81dbc6dbe800620e1f5d7ca63cbeb06758235ea7..d2019f676e60e293da292481d7523c958c8cb71e 100644 --- a/notification/ans_standard/actsansnotificationremove/Test.json +++ b/notification/ans_standard/actsansnotificationremove/Test.json @@ -2,9 +2,9 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "21600000", "package": "com.example.actsansnotificationremove", - "shell-timeout": "60000" + "shell-timeout": "21600000" }, "kits": [ { diff --git a/notification/ans_standard/actsansnotificationremove/entry/package.json b/notification/ans_standard/actsansnotificationremove/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/actsansnotificationremove/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/actsansslottest/BUILD.gn b/notification/ans_standard/actsansslottest/BUILD.gn index e48c3c87d6333e9f80b603ad9a309bbb337bab0e..351d6873cb8f38478917801ac65ae49b08cc80bf 100644 --- a/notification/ans_standard/actsansslottest/BUILD.gn +++ b/notification/ans_standard/actsansslottest/BUILD.gn @@ -19,10 +19,7 @@ group("ActsAnsSlotTest") { deps = [ "actsansgetslottestcallback:ActsAnsGetSlotTestCallback", "actsansgetslottestpromise:ActsAnsGetSlotTestPromise", - "actsanslotbybundle:ActsAnsSlotByBundle", "actsansremoveslottest:ActsAnsRemoveSlotTest", - "actsansslotsystemcallback:ActsAnsSlotSystemCallback", - "actsansslotsystempromise:ActsAnsSlotSystemPromise", ] } } diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/BUILD.gn b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/BUILD.gn old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/Test.json b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/Test.json old mode 100644 new mode 100755 index c5aef8f8cd23f6db9c0bcf8c9f848df9dc9ee2e6..1f14b510c3e8331cb0b07912b23d520ce881d752 --- a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/Test.json +++ b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansgetslottestcallback", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/package.json b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/package.json new file mode 100755 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/config.json b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/config.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/app.js b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/app.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/i18n/en-US.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/i18n/zh-CN.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/pages/index/index.css old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/pages/index/index.hml old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/default/pages/index/index.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/resources/base/element/string.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/resources/base/media/icon.png old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/test/ExampleJsunit.test.js old mode 100644 new mode 100755 index 7bf5c0c992ffdbe254890b293861796bdf6944a2..c2aaa75f5b98fb23c45f4f3abe3719e26ef31f96 --- a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/test/ExampleJsunit.test.js +++ b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/test/ExampleJsunit.test.js @@ -17,31 +17,31 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from ' describe('ActsAnsGetSlotTestCallback', function () { - function addSlotActsAnsGetSlotTestCallback_0100(err){ + function addSlotActsAnsGetSlotTestCallbackFirst(err){ console.debug("====>addSlotActsAnsGetSlotTestCallback_0100 enter====>"); console.debug("====>addSlotActsAnsGetSlotTestCallback_0100 err: ====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); console.debug("====>addSlotActsAnsGetSlotTestCallback_0100 finish====>"); } - function addSlotActsAnsGetSlotTestCallback_0200(err, data){ + function addSlotActsAnsGetSlotTestCallbackSecond(err, data){ console.debug("====>addSlotActsAnsGetSlotTestCallback_0200 enter====>"); console.debug("====>addSlotActsAnsGetSlotTestCallback_0200 err: ====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); console.debug("====>addSlotActsAnsGetSlotTestCallback_0200 finish====>"); } - function addSlotActsAnsGetSlotTestCallback_0300(err){ + function addSlotActsAnsGetSlotTestCallbackThird(err){ console.debug("====>addSlotActsAnsGetSlotTestCallback_0300 enter====>"); console.debug("====>addSlotActsAnsGetSlotTestCallback_0300 err: ====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); console.debug("====>addSlotActsAnsGetSlotTestCallback_0300 finish====>"); } - function addSlotActsAnsGetSlotTestCallback_0400(err){ + function addSlotActsAnsGetSlotTestCallbackFourth(err){ console.debug("====>addSlotActsAnsGetSlotTestCallback_0400 enter====>"); console.debug("====>addSlotActsAnsGetSlotTestCallback_0400 err: ====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); console.debug("====>addSlotActsAnsGetSlotTestCallback_0400 finish====>"); } - function addSlotActsAnsGetSlotTestCallback_0500(err){ + function addSlotActsAnsGetSlotTestCallbackFifth(err){ console.debug("====>addSlotActsAnsGetSlotTestCallback_0500 enter====>"); console.debug("====>addSlotActsAnsGetSlotTestCallback_0500 err: ====>" + JSON.stringify(err)); console.debug("====>addSlotActsAnsGetSlotTestCallback_0500 finish====>"); @@ -55,9 +55,9 @@ describe('ActsAnsGetSlotTestCallback', function () { it('ActsAnsGetSlotTestCallback_0100', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestCallback_0100 start====>"); console.debug("====>addSlot SlotType.SOCIAL_COMMUNICATION: ====>"); - await notification.addSlot(notification.SlotType.SOCIAL_COMMUNICATION, addSlotActsAnsGetSlotTestCallback_0100); + await notification.addSlot(notification.SlotType.SOCIAL_COMMUNICATION, addSlotActsAnsGetSlotTestCallbackFirst); console.debug("====>getSlot SlotType.SOCIAL_COMMUNICATION: ====>"); - await notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION, (err, data)=> { + await notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION, function (err, data){ console.debug("====>getSlotActsAnsGetSlotTestCallback_0100 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestCallback_0100 err====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); @@ -75,6 +75,9 @@ describe('ActsAnsGetSlotTestCallback', function () { console.debug("====>getSlotActsAnsGetSlotTestCallback_0100 finish====>"); done(); }); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestCallback_0100====>"); + }, 1000); }) /* @@ -84,7 +87,7 @@ describe('ActsAnsGetSlotTestCallback', function () { */ it('ActsAnsGetSlotTestCallback_0200', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestCallback_0200 start====>"); - function getSlotActsAnsGetSlotTestCallback_0200(err, data) { + function getSlotActsAnsGetSlotTestCallbackSecond(err, data) { console.debug("====>getSlotActsAnsGetSlotTestCallback_0200 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestCallback_0200 err====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); @@ -103,9 +106,12 @@ describe('ActsAnsGetSlotTestCallback', function () { done(); } console.debug("====>addSlot SlotType.SERVICE_INFORMATION: ====>"); - await notification.addSlot(notification.SlotType.SERVICE_INFORMATION, addSlotActsAnsGetSlotTestCallback_0200); + await notification.addSlot(notification.SlotType.SERVICE_INFORMATION, addSlotActsAnsGetSlotTestCallbackSecond); console.debug("====>getSlot SlotType.SERVICE_INFORMATION: ====>"); - await notification.getSlot(notification.SlotType.SERVICE_INFORMATION, getSlotActsAnsGetSlotTestCallback_0200); + await notification.getSlot(notification.SlotType.SERVICE_INFORMATION, getSlotActsAnsGetSlotTestCallbackSecond); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestCallback_0200====>"); + }, 1000); }) /* @@ -115,7 +121,7 @@ describe('ActsAnsGetSlotTestCallback', function () { */ it('ActsAnsGetSlotTestCallback_0300', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestCallback_0300 start====>"); - function getSlotActsAnsGetSlotTestCallback_0300(err, data) { + function getSlotActsAnsGetSlotTestCallbackThird(err, data) { console.debug("====>getSlotActsAnsGetSlotTestCallback_0300 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestCallback_0300 err====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); @@ -134,9 +140,12 @@ describe('ActsAnsGetSlotTestCallback', function () { done(); } console.debug("====>addSlot SlotType.CONTENT_INFORMATION: ====>"); - await notification.addSlot(notification.SlotType.CONTENT_INFORMATION, addSlotActsAnsGetSlotTestCallback_0300); + await notification.addSlot(notification.SlotType.CONTENT_INFORMATION, addSlotActsAnsGetSlotTestCallbackThird); console.debug("====>getSlot SlotType.CONTENT_INFORMATION: ====>"); - await notification.getSlot(notification.SlotType.CONTENT_INFORMATION, getSlotActsAnsGetSlotTestCallback_0300); + await notification.getSlot(notification.SlotType.CONTENT_INFORMATION, getSlotActsAnsGetSlotTestCallbackThird); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestCallback_0300====>"); + }, 1000); }) /* @@ -146,7 +155,7 @@ describe('ActsAnsGetSlotTestCallback', function () { */ it('ActsAnsGetSlotTestCallback_0400', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestCallback_0400 start====>"); - function getSlotActsAnsGetSlotTestCallback_0400(err, data) { + function getSlotActsAnsGetSlotTestCallbackFourth(err, data) { console.debug("====>getSlotActsAnsGetSlotTestCallback_0400 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestCallback_0400 err====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); @@ -165,9 +174,12 @@ describe('ActsAnsGetSlotTestCallback', function () { done(); } console.debug("====>addSlot SlotType.OTHER_TYPES: ====>"); - await notification.addSlot(notification.SlotType.OTHER_TYPES, addSlotActsAnsGetSlotTestCallback_0400); + await notification.addSlot(notification.SlotType.OTHER_TYPES, addSlotActsAnsGetSlotTestCallbackFourth); console.debug("====>getSlot SlotType.OTHER_TYPES: ====>"); - await notification.getSlot(notification.SlotType.OTHER_TYPES, getSlotActsAnsGetSlotTestCallback_0400); + await notification.getSlot(notification.SlotType.OTHER_TYPES, getSlotActsAnsGetSlotTestCallbackFourth); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestCallback_0400====>"); + }, 1000); }) /* @@ -177,7 +189,7 @@ describe('ActsAnsGetSlotTestCallback', function () { */ it('ActsAnsGetSlotTestCallback_0500', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestCallback_0500 start====>"); - function getSlotActsAnsGetSlotTestCallback_0500(err, data) { + function getSlotActsAnsGetSlotTestCallbackFifth(err, data) { console.debug("====>getSlotActsAnsGetSlotTestCallback_0500 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestCallback_0500 err====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); @@ -196,8 +208,11 @@ describe('ActsAnsGetSlotTestCallback', function () { done(); } console.debug("====>addSlot SlotType.UNKNOWN_TYPE: ====>"); - await notification.addSlot(notification.SlotType.UNKNOWN_TYPE, addSlotActsAnsGetSlotTestCallback_0500); + await notification.addSlot(notification.SlotType.UNKNOWN_TYPE, addSlotActsAnsGetSlotTestCallbackFifth); console.debug("====>getSlot SlotType.UNKNOWN_TYPE: ====>"); - await notification.getSlot(notification.SlotType.UNKNOWN_TYPE, getSlotActsAnsGetSlotTestCallback_0500); + await notification.getSlot(notification.SlotType.UNKNOWN_TYPE, getSlotActsAnsGetSlotTestCallbackFifth); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestCallback_0500====>"); + }, 1000); }) }) \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/test/List.test.js b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/entry/src/main/js/test/List.test.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestcallback/signature/openharmony_sx.p7b b/notification/ans_standard/actsansslottest/actsansgetslottestcallback/signature/openharmony_sx.p7b old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/BUILD.gn b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/BUILD.gn old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/Test.json b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/Test.json old mode 100644 new mode 100755 index 57953ad5ac0d69b4a50ced05307744b28659bae2..b8516b82655f7163a2e7448c7dc6f01c4c8a13ae --- a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/Test.json +++ b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansgetslottestpromise", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/package.json b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/package.json new file mode 100755 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/config.json b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/config.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/app.js b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/app.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/i18n/en-US.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/i18n/zh-CN.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/pages/index/index.css old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/pages/index/index.hml old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/default/pages/index/index.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/resources/base/element/string.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/resources/base/media/icon.png old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/test/ExampleJsunit.test.js old mode 100644 new mode 100755 index 779fb0ddb861e3825cdc7e854cb36bdc53c8f588..c8bef7c39923ff06b56eeedaeeb70c7378a93bd9 --- a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/test/ExampleJsunit.test.js +++ b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/test/ExampleJsunit.test.js @@ -24,11 +24,11 @@ describe('ActsAnsGetSlotTestPromise', function () { */ it('ActsAnsGetSlotTestPromise_0100', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestPromise_0100 start====>"); - await notification.addSlot(notification.SlotType.SOCIAL_COMMUNICATION).then(() => { + notification.addSlot(notification.SlotType.SOCIAL_COMMUNICATION).then(() => { console.debug("====>addSlotActsAnsGetSlotTestPromise_0100 enter====>"); }) console.debug("====>getSlot SlotType.SOCIAL_COMMUNICATION: ====>"); - await notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION).then((data) => { + notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION).then((data) => { console.debug("====>getSlotActsAnsGetSlotTestPromise_0100 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestPromise_0100 data====>" + JSON.stringify(data)); expect(data.type).assertEqual(notification.SlotType.SOCIAL_COMMUNICATION); @@ -42,9 +42,12 @@ describe('ActsAnsGetSlotTestPromise', function () { expect(data.lightEnabled).assertEqual(false); expect(data.lightColor).assertEqual(0); console.debug("====>getSlotActsAnsGetSlotTestPromise_0100 finish====>"); + done(); }) console.debug("====>ActsAnsGetSlotTestPromise_0100 end====>"); - done(); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestPromise_0100====>"); + }, 1000); }) /* @@ -54,13 +57,13 @@ describe('ActsAnsGetSlotTestPromise', function () { */ it('ActsAnsGetSlotTestPromise_0200', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestPromise_0200 start====>"); - await notification.addSlot(notification.SlotType.SERVICE_INFORMATION).then(() => { - console.debug("====>addSlotByTypePromise SERVICE_INFORMATION ActsAnsGetSlotTestPromise_0200 enter====>"); + notification.addSlot(notification.SlotType.SERVICE_INFORMATION).then(() => { + console.debug("====>addSlotByTypePromise SERVICE_INFORMATION ActsAnsGetSlotTestPromise_0200 enter"); }) console.debug("====>getSlot SlotType.SERVICE_INFORMATION: ====>"); - await notification.getSlot(notification.SlotType.SERVICE_INFORMATION).then((data) => { + notification.getSlot(notification.SlotType.SERVICE_INFORMATION).then((data) => { console.debug("====>getSlotPromise SERVICE_INFORMATION ActsAnsGetSlotTestPromise_0200 enter====>"); - console.debug("====>getSlotPromise SERVICE_INFORMATION ActsAnsGetSlotTestPromise_0200 data====>" + JSON.stringify(data)); + console.debug("====>getSlotPromise ActsAnsGetSlotTestPromise_0200 data====>" + JSON.stringify(data)); expect(data.type).assertEqual(notification.SlotType.SERVICE_INFORMATION); expect(data.level).assertEqual(3); expect(data.desc).assertEqual(""); @@ -72,9 +75,12 @@ describe('ActsAnsGetSlotTestPromise', function () { expect(data.lightEnabled).assertEqual(false); expect(data.lightColor).assertEqual(0); console.debug("====>getSlotPromise SERVICE_INFORMATION ActsAnsGetSlotTestPromise_0200 finish====>"); + done(); }) console.debug("====>ActsAnsGetSlotTestPromise_0200 end====>"); - done(); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestPromise_0200====>"); + }, 1000); }) /* @@ -85,13 +91,13 @@ describe('ActsAnsGetSlotTestPromise', function () { it('ActsAnsGetSlotTestPromise_0300', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestPromise_0300 Promise start====>"); console.debug("====>addSlot SlotType.CONTENT_INFORMATION: ====>"); - await notification.addSlot(notification.SlotType.CONTENT_INFORMATION).then(() => { - console.debug("====>addSlotByTypePromise CONTENT_INFORMATION ActsAnsGetSlotTestPromise_0300 enter====>"); + notification.addSlot(notification.SlotType.CONTENT_INFORMATION).then(() => { + console.debug("====>addSlotByTypePromise CONTENT_INFORMATION ActsAnsGetSlotTestPromise_0300 enter"); }) console.debug("====>getSlot SlotType.CONTENT_INFORMATION: ====>"); - await notification.getSlot(notification.SlotType.CONTENT_INFORMATION).then((data) => { + notification.getSlot(notification.SlotType.CONTENT_INFORMATION).then((data) => { console.debug("====>getSlotPromise CONTENT_INFORMATION ActsAnsGetSlotTestPromise_0300 enter====>"); - console.debug("====>getSlotPromise CONTENT_INFORMATION ActsAnsGetSlotTestPromise_0300 data====>" + JSON.stringify(data)); + console.debug("====>getSlotPromise ActsAnsGetSlotTestPromise_0300 data====>" + JSON.stringify(data)); expect(data.type).assertEqual(notification.SlotType.CONTENT_INFORMATION); expect(data.level).assertEqual(3); expect(data.desc).assertEqual(""); @@ -103,9 +109,12 @@ describe('ActsAnsGetSlotTestPromise', function () { expect(data.lightEnabled).assertEqual(false); expect(data.lightColor).assertEqual(0); console.debug("====>getSlotPromise CONTENT_INFORMATION ActsAnsGetSlotTestPromise_0300 finish====>"); + done(); }) console.info("====>ActsAnsGetSlotTestPromise_0300 end====>"); - done(); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestPromise_0300====>"); + }, 1000); }) /* @@ -116,13 +125,13 @@ describe('ActsAnsGetSlotTestPromise', function () { it('ActsAnsGetSlotTestPromise_0400', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestPromise_0400 start====>"); console.debug("====>addSlot SlotType.OTHER_TYPES: ====>"); - await notification.addSlot(notification.SlotType.OTHER_TYPES).then(() => { - console.debug("====>addSlotByTypePromise OTHER_TYPES AnsGetSlotByTypeAfterAddPromiseTest_0400 enter====>"); + notification.addSlot(notification.SlotType.OTHER_TYPES).then(() => { + console.debug("====>addSlotByTypePromise AnsGetSlotByTypeAfterAddPromiseTest_0400 enter====>"); }) console.debug("====>getSlot SlotType.OTHER_TYPES: ====>"); - await notification.getSlot(notification.SlotType.OTHER_TYPES).then((data) => { + notification.getSlot(notification.SlotType.OTHER_TYPES).then((data) => { console.debug("====>getSlotPromise OTHER_TYPES ActsAnsGetSlotTestPromise_0400 enter====>"); - console.debug("====>getSlotPromise OTHER_TYPES ActsAnsGetSlotTestPromise_0400 data====>" + JSON.stringify(data)); + console.debug("====>getSlotPromise ActsAnsGetSlotTestPromise_0400 data====>" + JSON.stringify(data)); expect(data.type).assertEqual(notification.SlotType.OTHER_TYPES); expect(data.level).assertEqual(3); expect(data.desc).assertEqual(""); @@ -134,9 +143,12 @@ describe('ActsAnsGetSlotTestPromise', function () { expect(data.lightEnabled).assertEqual(false); expect(data.lightColor).assertEqual(0); console.debug("====>getSlotPromise OTHER_TYPES ActsAnsGetSlotTestPromise_0400 finish====>"); + done(); }) console.debug("====>ActsAnsGetSlotTestPromise_0400 end====>"); - done(); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestPromise_0400====>"); + }, 1000); }) /* @@ -147,13 +159,13 @@ describe('ActsAnsGetSlotTestPromise', function () { it('ActsAnsGetSlotTestPromise_0500', 0, async function (done) { console.debug("====>ActsAnsGetSlotTestPromise_0500 start====>"); console.debug("====>addSlot SlotType.UNKNOWN_TYPE: ====>"); - await notification.addSlot(notification.SlotType.UNKNOWN_TYPE).then(() => { + notification.addSlot(notification.SlotType.UNKNOWN_TYPE).then(() => { console.debug("====>addSlotByTypePromise UNKNOWN_TYPE ActsAnsGetSlotTestPromise_0500 enter====>"); }) console.debug("====>getSlot SlotType.UNKNOWN_TYPE: ====>"); - await notification.getSlot(notification.SlotType.UNKNOWN_TYPE).then((data) => { + notification.getSlot(notification.SlotType.UNKNOWN_TYPE).then((data) => { console.debug("====>getSlotPromise UNKNOWN_TYPE ActsAnsGetSlotTestPromise_0500 enter====>"); - console.debug("====>getSlotPromise UNKNOWN_TYPE ActsAnsGetSlotTestPromise_0500 data====>" + JSON.stringify(data)); + console.debug("====>getSlotPromise ActsAnsGetSlotTestPromise_0500 data====>" + JSON.stringify(data)); expect(data.type).assertEqual(notification.SlotType.OTHER_TYPES); expect(data.level).assertEqual(3); expect(data.desc).assertEqual(""); @@ -165,8 +177,11 @@ describe('ActsAnsGetSlotTestPromise', function () { expect(data.lightEnabled).assertEqual(false); expect(data.lightColor).assertEqual(0); console.debug("====>getSlotPromise UNKNOWN_TYPE ActsAnsGetSlotTestPromise_0500 finish====>"); + done(); }) console.debug("====>ActsAnsGetSlotTestPromise_0500 end====>"); - done(); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestPromise_0500====>"); + }, 1000); }) }) \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/test/List.test.js b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/entry/src/main/js/test/List.test.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansgetslottestpromise/signature/openharmony_sx.p7b b/notification/ans_standard/actsansslottest/actsansgetslottestpromise/signature/openharmony_sx.p7b old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/BUILD.gn b/notification/ans_standard/actsansslottest/actsanslotbybundle/BUILD.gn deleted file mode 100644 index a28dd064352fe75c874728dc86afd7f2f920b1c7..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsSlotByBundle") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsSlotByBundle" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/Test.json b/notification/ans_standard/actsansslottest/actsanslotbybundle/Test.json deleted file mode 100644 index 2201313be4fb0ee35616db08e3cd5d7559242d7d..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansslotbybundle", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsSlotByBundle.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/config.json b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/config.json deleted file mode 100644 index e1367d83bcb6583d9f09a44f3011ae97d50d8947..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.example.actsansslotbybundle", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 4, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansslotbybundle", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansslotbybundle.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/app.js b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 13ae33e07e3a90032d5fb5589183072449422c77..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - {{ title }} - -
diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index 83cdb156001db9cf47720c68b41d0701fe5a7444..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "测试" - }, - onInit() { - this.title = this.data.title; - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - const reportExtend = new ReportExtend(file) - core.addService('expect', expectExtend) - core.addService('report', reportExtend) - - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - }, -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 6fdf5cecb3cbe3692524ffd403e5185d1e98b8cc..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "ActsAnsSlotByBundle" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index c73354680ee0a259241d217d313594ec68e5dd02..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,135 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsSlotByBundle', function () { - - /* - * @tc.number : ActsAnsSlotByBundle_0100 - * @tc.name : Verify getSlot SOCIAL_COMMUNICATION - * @tc.desc : After setSlot, call the getSlotsByBundle interface to - * check whether the information is consistent.(promise) - */ - it('ActsAnsSlotByBundle_0100', 0, async function (done) { - console.debug("====>ActsAnsSlotByBundle_0100 start====>"); - var bundleoption = { - bundle: "com.example.actsansgettest" - } - var notificationslot = { - type: notification.SlotType.SERVICE_INFORMATION, - level:4 - } - notification.addSlot(notification.SlotType.SERVICE_INFORMATION).then(() => { - console.debug("====>addSlotByTypePromise SERVICE_INFORMATION enter====>"); - console.debug("====>getSlotsByBundle1 start====>"); - notification.getSlotsByBundle(bundleoption).then((data)=>{ - console.debug("====>getSlotsByBundle1====>" + JSON.stringify(data)); - expect(data[0].type).assertEqual(2) - expect(data[0].level).assertEqual(3) - expect(data[0].badgeFlag).assertEqual(true) - expect(data[0].bypassDnd).assertEqual(false) - expect(data[0].lockscreenVisibility).assertEqual(2) - expect(data[0].vibrationEnabled).assertEqual(true) - expect(data[0].lightEnabled).assertEqual(false) - expect(data[0].lightColor).assertEqual(0) - console.debug("====>getSlotsByBundle1 finish====>"); - console.debug("====>setSlotByBundle start====>"); - notification.setSlotByBundle(bundleoption,notificationslot).then(()=>{ - console.debug("====>setSlotsByBundle====>") - console.debug("====>getSlotsByBundle1.1 start====>"); - notification.getSlotsByBundle(bundleoption).then((data)=>{ - console.debug("====>getSlotsByBundle1.1====>" + JSON.stringify(data)); - expect(data[0].type).assertEqual(2) - expect(data[0].level).assertEqual(4) - expect(data[0].badgeFlag).assertEqual(true) - expect(data[0].bypassDnd).assertEqual(false) - expect(data[0].lockscreenVisibility).assertEqual(2) - expect(data[0].vibrationEnabled).assertEqual(true) - expect(data[0].lightEnabled).assertEqual(false) - expect(data[0].lightColor).assertEqual(0) - console.debug("====>getSlotsByBundle1.1 finish====>"); - notification.getSlotNumByBundle(bundleoption).then((data)=>{ - console.debug("====>getSlotNumAsBundle1====>" + JSON.stringify(data)); - expect(data).assertEqual(1) - done(); - }) - }) - }) - }) - }) - - - - - - }) - - /* - * @tc.number : ActsAnsSlotByBundle_0100 - * @tc.name : Verify getSlot SOCIAL_COMMUNICATION - * @tc.desc : After setSlot, call the getSlotsByBundle interface to - * check whether the information is consistent.(callback) - */ - it('ActsAnsSetSlotByBundle_0200', 0, async function (done) { - console.debug("====>ActsAnsSlotByBundle_0200 start====>"); - var bundleoption = { - bundle: "com.example.actsansgettest" - } - var notificationslot = { - type: notification.SlotType.SERVICE_INFORMATION, - level:4 - } - notification.addSlot(notification.SlotType.SERVICE_INFORMATION).then(() => { - console.debug("====>addSlotByTypePromise SERVICE_INFORMATION enter====>"); - console.debug("====>getSlotsByBundle2 start====>"); - notification.getSlotsByBundle(bundleoption,(err,data)=>{ - console.debug("====>getSlotsByBundle2====>" + JSON.stringify(data)); - expect(data[0].type).assertEqual(2) - expect(data[0].level).assertEqual(3) - expect(data[0].badgeFlag).assertEqual(true) - expect(data[0].bypassDnd).assertEqual(false) - expect(data[0].lockscreenVisibility).assertEqual(2) - expect(data[0].vibrationEnabled).assertEqual(true) - expect(data[0].lightEnabled).assertEqual(false) - expect(data[0].lightColor).assertEqual(0) - console.debug("====>getSlotsByBundle2 finish====>"); - console.debug("====>setSlotByBundle start====>"); - notification.setSlotByBundle(bundleoption,notificationslot,()=>{ - console.debug("====>setSlotsByBundle====>") - console.debug("====>getSlotsByBundle2.1 start====>"); - notification.getSlotsByBundle(bundleoption,(err,data)=>{ - console.debug("====>getSlotsByBundle2.1====>" + JSON.stringify(data)); - expect(data[0].type).assertEqual(2) - expect(data[0].level).assertEqual(4) - expect(data[0].badgeFlag).assertEqual(true) - expect(data[0].bypassDnd).assertEqual(false) - expect(data[0].lockscreenVisibility).assertEqual(2) - expect(data[0].vibrationEnabled).assertEqual(true) - expect(data[0].lightEnabled).assertEqual(false) - expect(data[0].lightColor).assertEqual(0) - console.debug("====>getSlotsByBundle2.1 finish====>"); - notification.getSlotNumByBundle(bundleoption,(err,data)=>{ - console.debug("====>getSlotNumAsBundle2====>" + JSON.stringify(data)); - expect(data).assertEqual(1) - done(); - }) - }) - }) - }) - }) - - }) -}) diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/test/List.test.js b/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsanslotbybundle/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsanslotbybundle/signature/openharmony_sx.p7b b/notification/ans_standard/actsansslottest/actsanslotbybundle/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/actsansslottest/actsanslotbybundle/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/BUILD.gn b/notification/ans_standard/actsansslottest/actsansremoveslottest/BUILD.gn old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/Test.json b/notification/ans_standard/actsansslottest/actsansremoveslottest/Test.json old mode 100644 new mode 100755 index 5698e55a7e840a71e2402c4e0218d05899db764f..003fe8c686e1d742a4094aa95c09a2fb84c9efc8 --- a/notification/ans_standard/actsansslottest/actsansremoveslottest/Test.json +++ b/notification/ans_standard/actsansslottest/actsansremoveslottest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansremoveslottest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/package.json b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/package.json new file mode 100755 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/config.json b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/config.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/app.js b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/app.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/i18n/en-US.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/i18n/zh-CN.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/pages/index/index.css old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/pages/index/index.hml old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/default/pages/index/index.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/resources/base/element/string.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/resources/base/media/icon.png old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/test/ExampleJsunit.test.js old mode 100644 new mode 100755 index 6643eabf93f15117a37b7d04a7e7ce41715460f1..39602b85aa1025712cdca26a1d3c223bf2b4f46b --- a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/test/ExampleJsunit.test.js +++ b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/test/ExampleJsunit.test.js @@ -24,11 +24,11 @@ describe('ActsAnsRemoveSlotTest', function () { */ it('ActsAnsRemoveSlotTest_0100', 0, async function (done) { console.debug("====>ActsAnsRemoveSlotTest_0100 start====>"); - await notification.addSlot(notification.SlotType.SOCIAL_COMMUNICATION).then(() => { + notification.addSlot(notification.SlotType.SOCIAL_COMMUNICATION).then(() => { console.debug("====>addSlotActsAnsGetSlotTestPromise_0100 enter====>"); }) console.debug("====>getSlot SlotType.SOCIAL_COMMUNICATION: ====>"); - await notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION).then((data) => { + notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION).then((data) => { console.debug("====>getSlotActsAnsGetSlotTestPromise_0100 enter====>"); console.debug("====>getSlotActsAnsGetSlotTestPromise_0100 data====>" + JSON.stringify(data)); expect(data.type).assertEqual(notification.SlotType.SOCIAL_COMMUNICATION); @@ -43,7 +43,7 @@ describe('ActsAnsRemoveSlotTest', function () { expect(data.lightColor).assertEqual(0); console.debug("====>getSlotActsAnsGetSlotTestPromise_0100 finish====>"); }) - await notification.removeSlot(notification.SlotType.SOCIAL_COMMUNICATION, (err)=>{ + notification.removeSlot(notification.SlotType.SOCIAL_COMMUNICATION, (err)=>{ console.debug("====>removeSlot first time err====>" + JSON.stringify(err)); expect(err.code).assertEqual(0); notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION, (err, data)=>{ @@ -59,5 +59,8 @@ describe('ActsAnsRemoveSlotTest', function () { }) }) }) + setTimeout(function(){ + console.debug("====>time out ActsAnsRemoveSlotTest_0100====>"); + }, 10000); }) -}) \ No newline at end of file +}) \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/test/List.test.js b/notification/ans_standard/actsansslottest/actsansremoveslottest/entry/src/main/js/test/List.test.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansremoveslottest/signature/openharmony_sx.p7b b/notification/ans_standard/actsansslottest/actsansremoveslottest/signature/openharmony_sx.p7b old mode 100644 new mode 100755 diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/BUILD.gn b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/BUILD.gn deleted file mode 100644 index 1e410fb08148ce1e4eccc50a36ba9b96c62bec7f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsSlotSystemCallback") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsSlotSystemCallback" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/Test.json b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/Test.json deleted file mode 100644 index d46c274f1a0a5bd13fe15daa74c4124ec8391b2f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansslotsystemcallback", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsSlotSystemCallback.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/config.json b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/config.json deleted file mode 100644 index 044a903cd3feeb911b55eac07e443659ecfaabfd..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/config.json +++ /dev/null @@ -1,61 +0,0 @@ -{ - "app": { - "bundleName": "com.example.actsansslotsystemcallback", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 4, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansslotsystemcallback", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansslotsystemcallback.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "visible": true, - "launchType": "standard" - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/app.js b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 485c1ea4f2631a1045e84574a6e492429c6152db..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - activeButton - -
diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index 7aff3db5909dc68ab4a5c524e768bfb6b2b8832d..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "测试slot接口callback形式:系统应用" - }, - onInit() { - this.title = this.data.title; - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - const reportExtend = new ReportExtend(file) - core.addService('expect', expectExtend) - core.addService('report', reportExtend) - - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - }, -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index d72e9b5082dd736e5edef2041303460fcb5d64f7..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "ActsAnsSlotSystemCallback" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index 6eb2649d42c358c357f282f634e1226a33efd4fd..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,236 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsSlotSystemCallback', function () { - - /* - * @tc.number : ActsAnsSlotSystemCallback_0100 - * @tc.name : Verify getSlots after adding slots and removeSlot - * @tc.desc : getSlots after adding all type slots and removing slot - */ - it('ActsAnsSlotSystemCallback_0100', 0, async function (done) { - console.debug("====>ActsAnsSlotSystemCallback_0100 start====>"); - async function timeOut(){ - console.debug("====>time out enter====>"); - await notification.getSlots((err, data)=>{ - console.debug("====>getSlots enter====>"); - console.debug("====>getSlots data====>" + JSON.stringify(err)); - expect(err.code).assertEqual(0); - console.debug("====>getSlots data====>" + JSON.stringify(data)); - try{ - expect(data[0].type).assertEqual(notification.SlotType.SOCIAL_COMMUNICATION); - expect(data[0].level).assertEqual(notification.SlotLevel.LEVEL_NONE); - expect(data[0].desc).assertEqual("slot_SOCIAL_COMMUNICATION_desc"); - expect(data[0].badgeFlag).assertEqual(false); - expect(data[0].bypassDnd).assertEqual(true); - expect(data[0].vibrationEnabled).assertEqual(true); - expect(data[0].sound).assertEqual("slot_SOCIAL_COMMUNICATION_sound"); - expect(data[0].lightEnabled).assertEqual(true); - expect(data[0].lightColor).assertEqual(1); - - expect(data[1].type).assertEqual(notification.SlotType.SERVICE_INFORMATION); - expect(data[1].level).assertEqual(notification.SlotLevel.LEVEL_MIN); - expect(data[1].desc).assertEqual("slot_SERVICE_INFORMATION_desc"); - expect(data[1].badgeFlag).assertEqual(false); - expect(data[1].bypassDnd).assertEqual(true); - expect(data[1].vibrationEnabled).assertEqual(true); - expect(data[1].sound).assertEqual("slot_SERVICE_INFORMATION_sound"); - expect(data[1].lightEnabled).assertEqual(true); - expect(data[1].lightColor).assertEqual(2); - - expect(data[2].type).assertEqual(notification.SlotType.CONTENT_INFORMATION); - expect(data[2].level).assertEqual(notification.SlotLevel.LEVEL_LOW); - expect(data[2].desc).assertEqual("slot_CONTENT_INFORMATION_desc"); - expect(data[2].badgeFlag).assertEqual(false); - expect(data[2].bypassDnd).assertEqual(true); - expect(data[2].vibrationEnabled).assertEqual(true); - expect(data[2].sound).assertEqual("slot_CONTENT_INFORMATION_sound"); - expect(data[2].lightEnabled).assertEqual(true); - expect(data[2].lightColor).assertEqual(3); - - expect(data[3].type).assertEqual(notification.SlotType.OTHER_TYPES); - expect(data[3].level).assertEqual(notification.SlotLevel.LEVEL_DEFAULT); - expect(data[3].desc).assertEqual("slot_OTHER_TYPES_desc"); - expect(data[3].badgeFlag).assertEqual(false); - expect(data[3].bypassDnd).assertEqual(true); - expect(data[3].vibrationEnabled).assertEqual(true); - expect(data[3].sound).assertEqual("slot_OTHER_TYPES_sound"); - expect(data[3].lightEnabled).assertEqual(true); - expect(data[3].lightColor).assertEqual(4); - console.debug("====>getSlots end====>"); - console.debug("====>ActsAnsSlotSystemCallback_0100 end====>"); - notification.removeSlot(notification.SlotType.SOCIAL_COMMUNICATION, (err)=>{ - console.debug("====>removeSlot SOCIAL_COMMUNICATION ActsAnsSlotSystemCallback_0100 err====>" + JSON.stringify(err)); - expect(err.code).assertEqual(0); - done(); - }) - }catch(err){ - console.error("====>getSlots catch err====>" + JSON.stringify(err)); - expect().assertFail(); - } - }) - } - console.debug("====>addSlot SOCIAL_COMMUNICATION====>"); - await notification.addSlot( - { - type: notification.SlotType.SOCIAL_COMMUNICATION, - level: notification.SlotLevel.LEVEL_NONE, - desc: "slot_SOCIAL_COMMUNICATION_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SOCIAL_COMMUNICATION_sound", - lightEnabled: true, - lightColor: 1 - }, - (err)=>{ - console.debug("====>addSlot SOCIAL_COMMUNICATION callback====>"); - expect(err.code).assertEqual(0); - }) - console.debug("====>addSlot SERVICE_INFORMATION====>"); - await notification.addSlot( - { - type: notification.SlotType.SERVICE_INFORMATION, - level: notification.SlotLevel.LEVEL_MIN, - desc: "slot_SERVICE_INFORMATION_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SERVICE_INFORMATION_sound", - lightEnabled: true, - lightColor: 2 - }, - (err)=>{ - console.debug("====>addSlot SERVICE_INFORMATION callback====>"); - expect(err.code).assertEqual(0); - }) - console.debug("====>addSlot CONTENT_INFORMATION====>"); - await notification.addSlot( - { - type: notification.SlotType.CONTENT_INFORMATION, - level: notification.SlotLevel.LEVEL_LOW, - desc: "slot_CONTENT_INFORMATION_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_CONTENT_INFORMATION_sound", - lightEnabled: true, - lightColor: 3 - }, - (err)=>{ - console.debug("====>addSlot CONTENT_INFORMATION callback====>"); - expect(err.code).assertEqual(0); - }) - console.debug("====>addSlot OTHER_TYPES====>"); - await notification.addSlot( - { - type: notification.SlotType.OTHER_TYPES, - level: notification.SlotLevel.LEVEL_DEFAULT, - desc: "slot_OTHER_TYPES_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_OTHER_TYPES_sound", - lightEnabled: true, - lightColor: 4 - }, - (err)=>{ - console.debug("====>addSlot OTHER_TYPES callback====>"); - expect(err.code).assertEqual(0); - }) - console.debug("====>addSlot UNKNOWN_TYPE====>"); - await notification.addSlot( - { - type: notification.SlotType.UNKNOWN_TYPE, - level: notification.SlotLevel.LEVEL_HIGH, - desc: "slot_UNKNOWN_TYPE_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_UNKNOWN_TYPE_sound", - lightEnabled: true, - lightColor: 5 - }, - (err)=>{ - console.debug("====>addSlot UNKNOWN_TYPE callback====>"); - expect(err.code).assertEqual(0); - }) - setTimeout(timeOut, 3000); - }) - - /* - * @tc.number : ActsAnsSlotSystemPromise_0200 - * @tc.name : Verify that the same type of slot is added repeatedly - * @tc.desc : the same type of slot is added repeatedly, and the obtained slot is added for the first time - */ - it('ActsAnsSlotSystemCallback_0200', 0, async function (done) { - console.debug("====>ActsAnsSlotSystemCallback_0200 start====>"); - async function timeOutTwo(){ - await notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION, (err, data) => { - console.debug("====>getSlotActsAnsSlotSystemCallback_0200 enter====>"); - console.debug("====>getSlotActsAnsSlotSystemCallback_0200 err====>" + JSON.stringify(err)); - expect(err.code).assertEqual(0); - console.debug("====>getSlotActsAnsSlotSystemCallback_0200 data====>" + JSON.stringify(data)); - expect(data.type).assertEqual(notification.SlotType.SOCIAL_COMMUNICATION); - expect(data.level).assertEqual(notification.SlotLevel.LEVEL_NONE); - expect(data.desc).assertEqual("slot_SOCIAL_COMMUNICATION_Desc_First"); - expect(data.badgeFlag).assertEqual(false); - expect(data.bypassDnd).assertEqual(true); - expect(data.vibrationEnabled).assertEqual(true); - expect(data.sound).assertEqual("slot_SOCIAL_COMMUNICATION_Sound_First"); - expect(data.lightEnabled).assertEqual(true); - expect(data.lightColor).assertEqual(1); - console.debug("====>getSlotActsAnsSlotSystemCallback_0200 finish====>"); - console.debug("====>ActsAnsSlotSystemCallback_0200 end====>"); - done(); - }) - } - console.debug("====>addSlot SOCIAL_COMMUNICATION====>"); - await notification.addSlot( - { - type: notification.SlotType.SOCIAL_COMMUNICATION, - level: notification.SlotLevel.LEVEL_NONE, - desc: "slot_SOCIAL_COMMUNICATION_Desc_First", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SOCIAL_COMMUNICATION_Sound_First", - lightEnabled: true, - lightColor: 1 - } - ).then(()=>{ - console.debug("====>addSlot SOCIAL_COMMUNICATION callback====>"); - }) - await notification.addSlot( - { - type: notification.SlotType.SOCIAL_COMMUNICATION, - level: notification.SlotLevel.LEVEL_DEFAULT, - desc: "slot_SOCIAL_COMMUNICATION_Desc_Second", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SOCIAL_COMMUNICATION_Sound_Second", - lightEnabled: true, - lightColor: 1 - } - ).then(()=>{ - console.debug("====>addSlot SOCIAL_COMMUNICATION callback====>"); - }) - console.debug("====>getSlot SlotType.SOCIAL_COMMUNICATION: ====>"); - setTimeout(timeOutTwo, 3000); - }) -}) \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/test/List.test.js b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/signature/openharmony_sx.p7b b/notification/ans_standard/actsansslottest/actsansslotsystemcallback/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/actsansslottest/actsansslotsystemcallback/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/BUILD.gn b/notification/ans_standard/actsansslottest/actsansslotsystempromise/BUILD.gn deleted file mode 100644 index 4ec4705a05147eadd7300d70d4bde58244afe80e..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsSlotSystemPromise") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsSlotSystemPromise" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/Test.json b/notification/ans_standard/actsansslottest/actsansslotsystempromise/Test.json deleted file mode 100644 index 44c4d1b99e1e7c4a64a834bc123fe0b4de2602b6..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansslotsystempromise", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsSlotSystemPromise.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/config.json b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/config.json deleted file mode 100644 index 25b845cb00399524e0248a14bf056ed781aff039..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/config.json +++ /dev/null @@ -1,61 +0,0 @@ -{ - "app": { - "bundleName": "com.example.actsansslotsystempromise", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 4, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansslotsystempromise", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansslotsystempromise.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "visible": true, - "launchType": "standard" - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/app.js b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 485c1ea4f2631a1045e84574a6e492429c6152db..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - activeButton - -
diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index 3f54ed774fbdcb38038484efc69ed8fcbeed51d3..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "测试slot接口promise形式:系统应用" - }, - onInit() { - this.title = this.data.title; - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - const reportExtend = new ReportExtend(file) - core.addService('expect', expectExtend) - core.addService('report', reportExtend) - - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - }, -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 754b2f285a7e24f9f6bac79868bd9cff48810575..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "ActsAnsSlotSystemPromise" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index cb430b5a63a55b2e42d7c2a66890860f2d13fb1b..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,270 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsSlotSystemPromise', function () { - - /* - * @tc.number : ActsAnsSlotSystemPromise_0100 - * @tc.name : Verify getSlots after adding slots and removeSlot - * @tc.desc : getSlots after adding all type slots and adding again after removing slot - */ - it('ActsAnsSlotSystemPromise_0100', 0, async function (done) { - console.debug("====>ActsAnsSlotTestSystem_0100 start====>"); - console.debug("====>addSlot SOCIAL_COMMUNICATION====>"); - await notification.addSlot( - { - type: notification.SlotType.SOCIAL_COMMUNICATION, - level: notification.SlotLevel.LEVEL_NONE, - desc: "slot_SOCIAL_COMMUNICATION_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SOCIAL_COMMUNICATION_sound", - lightEnabled: true, - lightColor: 1 - } - ).then(()=>{ - console.debug("====>addSlot SOCIAL_COMMUNICATION promise====>"); - }) - console.debug("====>addSlot SERVICE_INFORMATION====>"); - await notification.addSlot( - { - type: notification.SlotType.SERVICE_INFORMATION, - level: notification.SlotLevel.LEVEL_MIN, - desc: "slot_SERVICE_INFORMATION_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SERVICE_INFORMATION_sound", - lightEnabled: true, - lightColor: 2 - } - ).then(()=>{ - console.debug("====>addSlot SERVICE_INFORMATION promise====>"); - }) - console.debug("====>addSlot CONTENT_INFORMATION====>"); - await notification.addSlot( - { - type: notification.SlotType.CONTENT_INFORMATION, - level: notification.SlotLevel.LEVEL_LOW, - desc: "slot_CONTENT_INFORMATION_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_CONTENT_INFORMATION_sound", - lightEnabled: true, - lightColor: 3 - } - ).then(()=>{ - console.debug("====>addSlot CONTENT_INFORMATION promise====>"); - }) - console.debug("====>addSlot OTHER_TYPES====>"); - await notification.addSlot( - { - type: notification.SlotType.OTHER_TYPES, - level: notification.SlotLevel.LEVEL_DEFAULT, - desc: "slot_OTHER_TYPES_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_OTHER_TYPES_sound", - lightEnabled: true, - lightColor: 4 - } - ).then(()=>{ - console.debug("====>addSlot OTHER_TYPES promise====>"); - }) - console.debug("====>addSlot UNKNOWN_TYPE====>"); - await notification.addSlot( - { - type: notification.SlotType.UNKNOWN_TYPE, - level: notification.SlotLevel.LEVEL_HIGH, - desc: "slot_UNKNOWN_TYPE_desc", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_UNKNOWN_TYPE_sound", - lightEnabled: true, - lightColor: 5 - } - ).then(()=>{ - console.debug("====>addSlot UNKNOWN_TYPE promise====>"); - }) - await notification.getSlots().then((data)=>{ - console.debug("====>getSlots enter====>"); - console.debug("====>getSlots data====>" + JSON.stringify(data)); - try{ - expect(data[0].type).assertEqual(notification.SlotType.SOCIAL_COMMUNICATION); - expect(data[0].level).assertEqual(notification.SlotLevel.LEVEL_NONE); - expect(data[0].desc).assertEqual("slot_SOCIAL_COMMUNICATION_desc"); - expect(data[0].badgeFlag).assertEqual(false); - expect(data[0].bypassDnd).assertEqual(true); - expect(data[0].vibrationEnabled).assertEqual(true); - expect(data[0].sound).assertEqual("slot_SOCIAL_COMMUNICATION_sound"); - expect(data[0].lightEnabled).assertEqual(true); - expect(data[0].lightColor).assertEqual(1); - - expect(data[1].type).assertEqual(notification.SlotType.SERVICE_INFORMATION); - expect(data[1].level).assertEqual(notification.SlotLevel.LEVEL_MIN); - expect(data[1].desc).assertEqual("slot_SERVICE_INFORMATION_desc"); - expect(data[1].badgeFlag).assertEqual(false); - expect(data[1].bypassDnd).assertEqual(true); - expect(data[1].vibrationEnabled).assertEqual(true); - expect(data[1].sound).assertEqual("slot_SERVICE_INFORMATION_sound"); - expect(data[1].lightEnabled).assertEqual(true); - expect(data[1].lightColor).assertEqual(2); - - expect(data[2].type).assertEqual(notification.SlotType.CONTENT_INFORMATION); - expect(data[2].level).assertEqual(notification.SlotLevel.LEVEL_LOW); - expect(data[2].desc).assertEqual("slot_CONTENT_INFORMATION_desc"); - expect(data[2].badgeFlag).assertEqual(false); - expect(data[2].bypassDnd).assertEqual(true); - expect(data[2].vibrationEnabled).assertEqual(true); - expect(data[2].sound).assertEqual("slot_CONTENT_INFORMATION_sound"); - expect(data[2].lightEnabled).assertEqual(true); - expect(data[2].lightColor).assertEqual(3); - - expect(data[3].type).assertEqual(notification.SlotType.OTHER_TYPES); - expect(data[3].level).assertEqual(notification.SlotLevel.LEVEL_DEFAULT); - expect(data[3].desc).assertEqual("slot_OTHER_TYPES_desc"); - expect(data[3].badgeFlag).assertEqual(false); - expect(data[3].bypassDnd).assertEqual(true); - expect(data[3].vibrationEnabled).assertEqual(true); - expect(data[3].sound).assertEqual("slot_OTHER_TYPES_sound"); - expect(data[3].lightEnabled).assertEqual(true); - expect(data[3].lightColor).assertEqual(4); - console.debug("====>getSlots end====>"); - }catch(err){ - console.error("====>getSlots catch err====>" + JSON.stringify(err)); - expect().assertFail(); - } - }) - - await notification.removeSlot(notification.SlotType.SOCIAL_COMMUNICATION).then(()=>{ - console.debug("====>removeSlot SOCIAL_COMMUNICATION ActsAnsSlotSystemPromise_0100====>"); - }) - await notification.removeSlot(notification.SlotType.SERVICE_INFORMATION).then(()=>{ - console.debug("====>removeSlot SERVICE_INFORMATION ActsAnsSlotSystemPromise_0100====>"); - }) - await notification.removeSlot(notification.SlotType.CONTENT_INFORMATION).then(()=>{ - console.debug("====>removeSlot CONTENT_INFORMATION ActsAnsSlotSystemPromise_0100====>"); - }) - await notification.removeSlot(notification.SlotType.OTHER_TYPES).then(()=>{ - console.debug("====>removeSlot OTHER_TYPES ActsAnsSlotSystemPromise_0100====>"); - }) - await notification.removeSlot(notification.SlotType.UNKNOWN_TYPE).then(()=>{ - console.debug("====>removeSlot UNKNOWN_TYPE ActsAnsSlotSystemPromise_0100====>"); - }) - - await notification.getSlots().then((data)=>{ - console.debug("====>getSlots enter====>"); - console.debug("====>getSlots data====>" + JSON.stringify(data)); - }) - console.debug("====>addSlot SERVICE_INFORMATION second====>"); - await notification.addSlot( - { - type: notification.SlotType.SERVICE_INFORMATION, - level: notification.SlotLevel.LEVEL_DEFAULT, - desc: "slot_SERVICE_INFORMATION_Desc_Second", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SERVICE_INFORMATION_Sound_Second", - lightEnabled: true, - lightColor: 2 - } - ).then(()=>{ - console.debug("====>addSlot SERVICE_INFORMATION second====>"); - }) - await notification.getSlot(notification.SlotType.SERVICE_INFORMATION).then((data) => { - console.debug("====>getSlotPromise SERVICE_INFORMATION ActsAnsSlotSystemPromise_0100 enter====>"); - console.debug("====>getSlotPromise SERVICE_INFORMATION ActsAnsSlotSystemPromise_0100 data====>" + JSON.stringify(data)); - expect(data.type).assertEqual(notification.SlotType.SERVICE_INFORMATION); - expect(data.level).assertEqual(notification.SlotLevel.LEVEL_DEFAULT); - expect(data.desc).assertEqual("slot_SERVICE_INFORMATION_Desc_Second"); - expect(data.badgeFlag).assertEqual(false); - expect(data.bypassDnd).assertEqual(true); - expect(data.vibrationEnabled).assertEqual(true); - expect(data.sound).assertEqual("slot_SERVICE_INFORMATION_Sound_Second"); - expect(data.lightEnabled).assertEqual(true); - expect(data.lightColor).assertEqual(2); - console.debug("====>getSlotPromise SERVICE_INFORMATION ActsAnsSlotSystemPromise_0100 finish====>"); - }) - await notification.removeSlot(notification.SlotType.SERVICE_INFORMATION).then(()=>{ - console.debug("====>removeSlot SERVICE_INFORMATION ActsAnsSlotSystemPromise_0100====>"); - }) - console.debug("====>ActsAnsSlotTestSystem_0100 end====>"); - done(); - }) - - /* - * @tc.number : ActsAnsSlotSystemPromise_0200 - * @tc.name : Verify that the same type of slot is added repeatedly - * @tc.desc : the same type of slot is added repeatedly, and the obtained slot is added for the first time - */ - it('ActsAnsSlotSystemPromise_0200', 0, async function (done) { - console.debug("====>ActsAnsSlotSystemPromise_0200 start====>"); - console.debug("====>addSlot SOCIAL_COMMUNICATION====>"); - await notification.addSlot( - { - type: notification.SlotType.SOCIAL_COMMUNICATION, - level: notification.SlotLevel.LEVEL_NONE, - desc: "slot_SOCIAL_COMMUNICATION_Desc_First", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SOCIAL_COMMUNICATION_Sound_First", - lightEnabled: true, - lightColor: 1 - } - ).then(()=>{ - console.debug("====>addSlot SOCIAL_COMMUNICATION promise====>"); - }) - await notification.addSlot( - { - type: notification.SlotType.SOCIAL_COMMUNICATION, - level: notification.SlotLevel.LEVEL_DEFAULT, - desc: "slot_SOCIAL_COMMUNICATION_Desc_Second", - badgeFlag: false, - bypassDnd: true, - vibrationEnabled: true, - sound: "slot_SOCIAL_COMMUNICATION_Sound_Second", - lightEnabled: true, - lightColor: 1 - } - ).then(()=>{ - console.debug("====>addSlot SOCIAL_COMMUNICATION promise====>"); - }) - console.debug("====>getSlot SlotType.SOCIAL_COMMUNICATION: ====>"); - await notification.getSlot(notification.SlotType.SOCIAL_COMMUNICATION).then((data) => { - console.debug("====>getSlotActsAnsSlotSystemPromise_0200 enter====>"); - console.debug("====>getSlotActsAnsSlotSystemPromise_0200 data====>" + JSON.stringify(data)); - expect(data.type).assertEqual(notification.SlotType.SOCIAL_COMMUNICATION); - expect(data.level).assertEqual(notification.SlotLevel.LEVEL_NONE); - expect(data.desc).assertEqual("slot_SOCIAL_COMMUNICATION_Desc_First"); - expect(data.badgeFlag).assertEqual(false); - expect(data.bypassDnd).assertEqual(true); - expect(data.vibrationEnabled).assertEqual(true); - expect(data.sound).assertEqual("slot_SOCIAL_COMMUNICATION_Sound_First"); - expect(data.lightEnabled).assertEqual(true); - expect(data.lightColor).assertEqual(1); - console.debug("====>getSlotActsAnsSlotSystemPromise_0200 finish====>"); - }) - console.debug("====>ActsAnsSlotSystemPromise_0200 end====>"); - done(); - }) -}) \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/test/List.test.js b/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/actsansslottest/actsansslotsystempromise/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/actsansslottest/actsansslotsystempromise/signature/openharmony_sx.p7b b/notification/ans_standard/actsansslottest/actsansslotsystempromise/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/actsansslottest/actsansslotsystempromise/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/BUILD.gn b/notification/ans_standard/publish_test/BUILD.gn index 25caef6d500fbd8ce12913ceaddd6bdcfc130a75..13945e26936c43a7b4df3cd48de980263b65c212 100644 --- a/notification/ans_standard/publish_test/BUILD.gn +++ b/notification/ans_standard/publish_test/BUILD.gn @@ -16,18 +16,12 @@ group("publish_test") { testonly = true if (is_standard_system) { deps = [ - "activebutton:ActsAnsActionButtonTest", "actsanspublishcontroltest:ActsAnsPublishControlTest", "badgedisplayed:badgedisplayed", "badgedisplayedset:badgedisplayedset", "enablenotification:enablenotification", "enablenotificationset:enablenotificationset", - "getactive:getactive", "getwantagentinfo:getwantagentinfo", - "publishcontentype:ActsAnsNotificationTest", - "publishimage:ActsAnsPublishImageTest", - "subscribe:subscribe", - "unsubscribe:ActsAnsUnSubscriberTest", "wantagent:wantagent", ] } diff --git a/notification/ans_standard/publish_test/activebutton/BUILD.gn b/notification/ans_standard/publish_test/activebutton/BUILD.gn deleted file mode 100644 index 12c75c870f91ab20ade1cd0d44264dd9330543c7..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsActionButtonTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsActionButtonTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/activebutton/Test.json b/notification/ans_standard/publish_test/activebutton/Test.json deleted file mode 100644 index 02a875416ad5daaf3497671e58d6178ff955b0cf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansactionbuttontest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsActionButtonTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/config.json b/notification/ans_standard/publish_test/activebutton/entry/src/main/config.json deleted file mode 100644 index 360665edb13f03503c95ca9bc2dfe5c3b30fa5d7..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansactionbuttontest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansactionbuttontest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansactionbuttontest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 485c1ea4f2631a1045e84574a6e492429c6152db..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - activeButton - -
diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index eb3bb563e41888ba752c3a4da28e4d09cefec8b8..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "ActiveBtn" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/test/ActiveButton.js b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/test/ActiveButton.js deleted file mode 100644 index d87b9f2185479fb62cac9f0fa250d3b9a3ed8c8a..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/test/ActiveButton.js +++ /dev/null @@ -1,237 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notify from '@ohos.notification' -import wantagent from '@ohos.wantAgent' -import image from '@ohos.multimedia.image' -import { OperationType, Flags } from '@ohos.wantagent' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -var largeBuffer -var smallBuffer -var opts -var subInfo -var largeIcon -var smallIcon - -describe('ActsAnsActionButtonTest', function () { - console.info("===========ActsDoNotSubscriberTest start====================>"); - - //consume - function consumeCallback(err,data) { - console.debug("==========================>consumeDoNotCallbackOne data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data.actionButtons)).assertEqual('object') - for(let i=0; i" + data.actionButtons[i].title); - console.debug("======consumeCallback====sortings.hashCode:====>" + data.actionButtons[i].wantAgent); - console.debug("======consumeCallback====sortings.hashCode:====>" + data.actionButtons[i].icon); - } - } - //consume - function consumeCallbackTwo(err,data) { - console.debug("==========================>consumeDoNotCallbackTwo data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data.actionButtons)).assertEqual('object') - for(let i=0; i" + data.actionButtons[i].title); - console.debug("======consumeDoNotCallbackTwo====sortings.hashCode:====>" + data.actionButtons[i].wantAgent); - console.debug("======consumeCallback====sortings.hashCode:====>" + data.actionButtons[i].icon); - } - } - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeDoNotOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeDoNotCallback=======================>"); - } - function publishCallback200(){ - console.debug("==========================>publishCallback200=======================>"); - } - /* - * @tc.number: ActsDoNotSubscriber_test_0100 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsActiveButton_test_0100', 0, async function (done) { - console.debug("===============ActsActiveButton_test_0100======begin====================>"); - - var subInfo ={ - onConsum:consumeCallback, - onConnect:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - }catch(err) { - console.error('=ActsActiveButton_test_0100 订阅 activeButton err:'+err); - } - console.debug("===============ActsActiveButton_test_0100=======end3===================>"); - - var agentInfo = { - wants: [ - { - deviceId: "deviceId", - bundleName: "com.example.test", - abilityName: "com.example.test.TriggerAbility", - action: "action1", - entities: ["entity1"], - type: "MIMETYPE", - uri: "key={true,true,false}", - parameters: - { - mykey0: 2222, - mykey1: [1, 2, 3], - mykey2: "[1, 2, 3]", - mykey3: "ssssssssssssssssssssssssss", - mykey4: [false, true, false], - mykey5: ["qqqqq", "wwwwww", "aaaaaaaaaaaaaaaaa"], - mykey6: true, - } - } - ], - operationType: OperationType.START_ABILITY, - requestCode: 0, - wantAgentFlags:[Flags.UPDATE_PRESENT_FLAG] - }; - var wantAgentData = await wantagent.getWantAgent(agentInfo); - largeBuffer = new ArrayBuffer(64); - smallBuffer = new ArrayBuffer(32); - opts = {alphaType: 0, editable: true, pixelFormat: 4, scaleMode: 1, size: {height: 2, width: 3}} - const promise_Large = image.createPixelMap(largeBuffer, opts); - promise_Large.then((data) => { - console.debug("==========================createPixelMap_promise_Large=======================>"); - largeIcon = data; - console.debug("==========================createPixelMap_promise_Large largeIcon=======================>"+largeIcon); - }) - const promise_Small = image.createPixelMap(smallBuffer, opts); - promise_Small.then((data) => { - console.debug("==========================createPixelMap_promise_Small=======================>"); - smallIcon = data; - console.debug("==========================createPixelMap_promise_Small smallIcon=======================>"+smallIcon); - }) - var notificationRequest = { - content:{ - contentType: notify.ContentType.NOTIFICATION_CONTENT_LONG_TEXT, - longText : { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText: "long_text", - briefText: "long_briefText", - expandedTitle: "long_expandedTitle" - }, - }, - id: 1, - slotType : notify.SlotType.SERVICE_INFORMATION, - actionButtons: [{title:"button", wantAgent:wantAgentData,icon:largeIcon},{title:"button", wantAgent:wantAgentData,icon:smallIcon}] - } - await notify.publish(notificationRequest, publishCallback200); - console.info("===============ActsActiveButton_test_0100==========================>"); - done(); - }) - /* - * @tc.number: ActsActiveButton_test_0200 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsActiveButton_test_0200', 0, async function (done) { - console.debug("===============ActsActiveButton_test_0200======begin====================>"); - - var subInfo ={ - onConsum:consumeCallbackTwo, - onConnect:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - }catch(err) { - console.error('=ActsActiveButton_test_0200 订阅 activeButton err:'+err); - } - console.debug("===============ActsActiveButton_test_0200=======end===================>"); - - var agentInfoOne = { - wants: [ - { - deviceId: "deviceId", - bundleName: "com.example.test", - abilityName: "com.example.test.TriggerAbility", - action: "action1", - entities: ["entity1"], - type: "MIMETYPE", - uri: "key={true,true,false}", - parameters: - { - mykey0: 2222, - mykey1: [1, 2, 3], - mykey2: "[1, 2, 3]", - mykey3: "ssssssssssssssssssssssssss", - mykey4: [false, true, false], - mykey5: ["qqqqq", "wwwwww", "aaaaaaaaaaaaaaaaa"], - mykey6: true, - } - } - ], - operationType: OperationType.START_ABILITY, - requestCode: 0, - wantAgentFlags:[Flags.UPDATE_PRESENT_FLAG] - }; - var agentInfoTwo = { - wants: [ - { - deviceId: "deviceId", - bundleName: "com.example.test", - abilityName: "com.example.test.TriggerAbility", - action: "action1", - entities: ["entity1"], - type: "MIMETYPE", - uri: "key={true,true,false}", - } - ], - - }; - console.info("===============agentInfo2========================>"); - var wantAgentDataOne = await wantagent.getWantAgent(agentInfoOne); - var wantAgentDataTwo = await wantagent.getWantAgent(agentInfoTwo); - - smallBuffer = new ArrayBuffer(32); - opts = {alphaType: 0, editable: true, pixelFormat: 4, scaleMode: 1, size: {height: 2, width: 3}} - const promise_Large = image.createPixelMap(largeBuffer, opts); - promise_Large.then((data) => { - console.debug("==========================createPixelMap_promise_Large=======================>"); - largeIcon = data; - console.debug("==========================createPixelMap_promise_Large largeIcon=======================>"+largeIcon); - }) - var notificationRequest = { - content:{ - contentType: notify.ContentType.NOTIFICATION_CONTENT_LONG_TEXT, - longText : { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText: "long_text", - briefText: "long_briefText", - expandedTitle: "long_expandedTitle" - }, - }, - id: 1, - slotType : notify.SlotType.SERVICE_INFORMATION, - actionButtons: [{title:"button", wantAgent:wantAgentDataOne,icon:largeIcon},{title:"button", wantAgent:wantAgentDataTwo,icon:largeIcon}] - } - await notify.publish(notificationRequest, publishCallback200); - console.info("===============ActsActiveButton_test_0200==========================>"); - done(); - }) -}) - diff --git a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/activebutton/entry/src/main/js/test/List.test.js deleted file mode 100644 index f5aafb6b1ff0d6cd5df4786fa4125999fa2f1dd1..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/activebutton/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ActiveButton.js') diff --git a/notification/ans_standard/publish_test/activebutton/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/activebutton/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/activebutton/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/BUILD.gn b/notification/ans_standard/publish_test/actsanspublishcontroltest/BUILD.gn old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/Test.json b/notification/ans_standard/publish_test/actsanspublishcontroltest/Test.json old mode 100644 new mode 100755 index 59691c7c2e12d4e44ebf4d0f1e7f24b1b4a1d3c8..ced46323d5a1db582c4733ac0bb6211f70a8b241 --- a/notification/ans_standard/publish_test/actsanspublishcontroltest/Test.json +++ b/notification/ans_standard/publish_test/actsanspublishcontroltest/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanspublishcontroltest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/package.json b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/package.json new file mode 100755 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/config.json b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/config.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/app.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/i18n/en-US.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/i18n/zh-CN.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/pages/index/index.css old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/pages/index/index.hml old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/default/pages/index/index.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/resources/base/element/string.json old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/resources/base/media/icon.png old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/test/ExampleJsunit.test.js old mode 100644 new mode 100755 index f53c318f4d4a0e1111d97a3aaa3fd32990cec7d1..ff2b729ffcfdd1dbbe322eb6992442e3395e7581 --- a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/test/ExampleJsunit.test.js +++ b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/test/ExampleJsunit.test.js @@ -444,6 +444,6 @@ describe('ActsAnsPublishControlTest', function () { id: 20 }, publish_the_twentieth_notification); console.debug("====>time out start====>"); - setTimeout(timeOut, 3000); + setTimeout(timeOut, 15000); }) -}) \ No newline at end of file +}) \ No newline at end of file diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/actsanspublishcontroltest/entry/src/main/js/test/List.test.js old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/actsanspublishcontroltest/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/actsanspublishcontroltest/signature/openharmony_sx.p7b old mode 100644 new mode 100755 diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/Test.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/Test.json index 7ceed477119ca04df285db3edee420808a6f575e..ddc4bb104e6b88fb732fc02b74011848653a4b76 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplayfivetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/src/main/js/test/BadgeDisplay.js index 18cf209a013a2764cbd5a1ed41364a9c333ab79b..bb94dc414487a85261af69fb5be19958d4a5761f 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfive/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplayFiveTest', function () { console.info("===========ActsDoNotDisturbModeTest5 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplayFiveTest', function () { console.log("==========================>ActsBadgeDisplay_test_0900 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0900====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplay_test_1000 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplayFiveTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },"").then(console.log("==========================>ActsBadgeDisplay_test_1000 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_1000====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplay_test_0900 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplayFiveTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0900====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplay_test_1000 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplayFiveTest', function () { console.log("==========================>ActsSystemCanDisplay_test_1000 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_1000====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/Test.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/Test.json index d2585f2ba149ce2c404f2b9d8bb377a928115369..17d2d5aebfb811d682b7b3b4c8e5d1362b8caae3 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplayfourtest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/src/main/js/test/BadgeDisplay.js index d5772dfd9c39910bb6dcfe1101a700f8ed8d1be1..74b24dd65b43c9af13f9d6b3d5d3857eb5366356 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayfour/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplayFourTest', function () { console.info("===========ActsDoNotDisturbModeTest4 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplayFourTest', function () { console.log("==========================>ActsBadgeDisplay_test_0700 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0700====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplay_test_0800 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplayFourTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },100).then(console.log("==========================>ActsBadgeDisplay_test_0800 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0800====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplay_test_0700 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplayFourTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0700====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplay_test_0800 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplayFourTest', function () { console.log("==========================>ActsSystemCanDisplay_test_0800 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0800====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/Test.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/Test.json index f17fa4e105adf13317dab32704afaa628615e718..29d6a2ac1b748b439260197b9a8f1a872f9c54a7 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplayonetest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/src/main/js/test/BadgeDisplay.js index 0062abb4d0ef930da8f1d14b6f110f458ae904b2..a9b2697e99099c5c2eca58a2ad09c0728232e43b 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplayone/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplayOneTest', function () { console.info("===========ActsDoNotDisturbModeTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplayOneTest', function () { console.log("==========================>ActsBadgeDisplay_test_0100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0100====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplay_test_0200 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplayOneTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },true).then(console.log("==========================>ActsBadgeDisplay_test_0200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0200====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplay_test_0100 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplayOneTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0100====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplay_test_0200 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplayOneTest', function () { console.log("==========================>ActsSystemCanDisplay_test_0200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0200====>"); + }, time) }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/Test.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/Test.json index 1fe799d52506f4b8919134c9e7da8479164ff391..eedcebf26cca54cda6cc6271d8b67ab1b34e8600 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysixtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/src/main/js/test/BadgeDisplay.js index 172cf3272ee4f479f2254f02e3030e5fe565d4e7..bd2f76cccecb0fcc78751799cddf93da709183c1 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaysix/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySixTest', function () { console.info("===========ActsDoNotDisturbModeTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySixTest', function () { console.log("==========================>ActsBadgeDisplay_test_1100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_1100====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplay_test_1200 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySixTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },true).then(console.log("==========================>ActsBadgeDisplay_test_1200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_1200====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplay_test_1100 @@ -54,6 +60,9 @@ describe('ActsAnsBadgeDisplaySixTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_1100====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplay_test_1200 @@ -65,6 +74,9 @@ describe('ActsAnsBadgeDisplaySixTest', function () { console.log("==========================>ActsSystemCanDisplay_test_1200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_1200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/Test.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/Test.json index d5fafeb99d4f0d085aa629920e97789f8a9e3942..14dff563637c9f8feb7ef3943cf67825364d0cb7 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaytreetest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/src/main/js/test/BadgeDisplay.js index a84332a3f948dab1ee795cac0b2f99ea99f1ce79..4950b694f740435be78fed03c7e372c604fdf30c 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytree/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplayTreeTest', function () { console.info("===========ActsDoNotDisturbModeTest3 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplayTreeTest', function () { console.log("==========================>ActsBadgeDisplay_test_0500 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0500====>"); + }, time) }) /* * @tc.number: ActsBadgeDisplay_test_0600 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplayTreeTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },false).then(console.log("==========================>ActsBadgeDisplay_test_0600 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0600====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplay_test_0500 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplayTreeTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0500====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplay_test_0600 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplayTreeTest', function () { console.log("==========================>ActsSystemCanDisplay_test_0600 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0600====>"); + }, time) }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/Test.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/Test.json index f1db70defc8fad0294ce5c3231371278221b0415..3b99301e7e63ee2da90bd91a901f56da45e21a93 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaytwotest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/src/main/js/test/BadgeDisplay.js index 1bf0da500cbf6d751e4495458e488cccd1fda9a2..73e14df28192a8beee8087b01ad634231f57035b 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/badgedisplaytwo/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplayTwoTest', function () { console.info("===========ActsDoNotDisturbModeTest2 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplayTwoTest', function () { console.log("==========================>ActsBadgeDisplay_test_0300 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0300====>"); + }, time) }) /* * @tc.number: ActsBadgeDisplay_test_0400 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplayTwoTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },false).then(console.log("==========================>ActsBadgeDisplay_test_0400 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplay_test_0400====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplay_test_0300 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplayTwoTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsAnsGetSlotTestCallback_0100====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplay_test_0400 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplayTwoTest', function () { console.log("==========================>ActsSystemCanDisplay_test_0400 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplay_test_0400====>"); + }, time) }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/Test.json b/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/Test.json index 0bd710ade6adff4e79d4776f36d5c963a2159e6b..ec75c6b82a5cb4d15ef73c8583f9aabb069acbe1 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanslocalcandisplaytest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/package.json b/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/src/main/js/test/BadgeDisplay.js index 8ee6c0df48dd20fd7960a8c6f1eeaa27d76c9c6e..be30f87548fae1b6bf057bd61e6245f2b96afd9d 100644 --- a/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayed/localcandisplay/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsLocalCanDisplayTest', function () { console.info("===========ActsLocalCanDisplayTest start====================>"); /* @@ -29,6 +29,9 @@ describe('ActsAnsLocalCanDisplayTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsLocalCanDisplay_test_0100====>"); + }, time); }) /* * @tc.number: ActsLocalCanDisplay_test_0200 @@ -40,6 +43,9 @@ describe('ActsAnsLocalCanDisplayTest', function () { console.log("==========================>ActsLocalCanDisplay_test_0200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsLocalCanDisplay_test_0200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/Test.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/Test.json index 199c966ac095b6409d9c8b2c0349d043fc16f12a..9065c3303a878f5c67e93f3c81c3f0d59d73c07a 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysetfivetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/package.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/src/main/js/test/BadgeDisplay.js index 796dc206fb7e8d672d5c3b472bd1db4470ace359..705446a36f32fbbc87adc9aab0f8c661438abe43 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfive/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySetFiveTest', function () { console.info("===========ActsDoNotDisturbModeSetTest5 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySetFiveTest', function () { console.log("==========================>ActsBadgeDisplaySet_test_0900 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0900====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplaySet_test_1000 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySetFiveTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },"").then(console.log("==========================>ActsBadgeDisplaySet_test_1000 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_1000====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0900 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplaySetFiveTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0900====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_1000 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplaySetFiveTest', function () { console.log("==========================>ActsSystemCanDisplaySet_test_1000 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_1000====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/Test.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/Test.json index 2fcb46b19dd0d28f3b595df94b705071ae486cbd..365b90069db1478d9f56fff21dbcb211d7978f63 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysetfourtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/package.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/src/main/js/test/BadgeDisplay.js index 8aa1ea5e3132235ee4780a00b9c3eab09fc966e2..8799ae6bf2b2373612dbbed161971dda6b855880 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetfour/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySetFourTest', function () { console.info("===========ActsDoNotDisturbModeSetTest4 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySetFourTest', function () { console.log("==========================>ActsBadgeDisplaySet_test_0700 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0700====>"); + }, time) }) /* * @tc.number: ActsBadgeDisplay_test_0800 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySetFourTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },100).then(console.log("==========================>ActsBadgeDisplaySet_test_0800 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0800====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplaySet_test_0700 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplaySetFourTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0700====>"); + }, time) }) /* * @tc.number: ActsSystemCanDisplaySet_test_0800 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplaySetFourTest', function () { console.log("==========================>ActsSystemCanDisplaySet_test_0800 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0800====>"); + }, time) }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/Test.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/Test.json index f752e6fa97fd11d739786dca73bf5a85a04bce0d..5b9251c7bd66f3a0150ee08fe3dfa5950b8cca1a 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysetonetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/package.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/src/main/js/test/BadgeDisplay.js index f34a0c54678e100ded26e569fc3fc2dcc9eaa789..1dcfa1e40286aa5fae21440fb30cd4505f12e45b 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetone/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySetOneTest', function () { console.info("===========ActsAnsBadgeDisplaySetTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySetOneTest', function () { console.log("==========================>ActsBadgeDisplaySet_test_0100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0100====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplaySet_test_0200 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySetOneTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },true).then(console.log("==========================>ActsBadgeDisplaySet_test_0200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0200====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0100 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplaySetOneTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0100====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0200 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplaySetOneTest', function () { console.log("==========================>ActsSystemCanDisplaySet_test_0200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/Test.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/Test.json index 54fba1fc3d171e15c75d9905e81d20d0d97fe1ab..3000ddaeaa3b41daf4efb9092665981b3e0b9b7a 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysetsixtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/package.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/src/main/js/test/BadgeDisplay.js index 6d41cd5f33e9f4ebd1d4f83f8f9768ca1d7d4549..dcc821b92df41ea5cceb70fa44c5131d5134e9bd 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysetsix/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySetSixTest', function () { console.info("===========ActsDoNotDisturbModeSetTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySetSixTest', function () { console.log("==========================>ActsBadgeDisplaySet_test_1100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_1100====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplaySet_test_1200 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySetSixTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },true).then(console.log("==========================>ActsBadgeDisplaySet_test_1200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_1200====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_1100 @@ -54,6 +60,9 @@ describe('ActsAnsBadgeDisplaySetSixTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_1100====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_1200 @@ -65,6 +74,9 @@ describe('ActsAnsBadgeDisplaySetSixTest', function () { console.log("==========================>ActsSystemCanDisplaySet_test_1200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_1200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/Test.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/Test.json index 1ac28be62438b2a1368ad5bc0276077e4a2011a4..d765f61b57def7fb498bc26291679d7c7481a1d7 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysettreetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/package.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/src/main/js/test/BadgeDisplay.js index 3da36eca9f25146c423b521fe1a30c49ce5a110c..9ddc03a76c2f546e9b55cfbe361586a69fbedd29 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettree/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySetTreeTest', function () { console.info("===========ActsDoNotDisturbModeSetTest3 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySetTreeTest', function () { console.log("==========================>ActsBadgeDisplaySet_test_0500 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0500====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplaySet_test_0600 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySetTreeTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },false).then(console.log("==========================>ActsBadgeDisplaySet_test_0600 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0600====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0500 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplaySetTreeTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0500====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0600 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplaySetTreeTest', function () { console.log("==========================>ActsSystemCanDisplaySet_test_0600 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0600====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/Test.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/Test.json index 1ee9eb98e307f7ef2abe8c96179d8323f05c6098..d067cc9d9a2100bdc7ad07d256d0fbfbb3a150fa 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/Test.json +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansbadgedisplaysettwotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/package.json b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/src/main/js/test/BadgeDisplay.js index 1b2ffa4bbb1c20a39f2ed042f1247e0bd276f5e5..996eef93fbf39e6dfc0fe55d7a8b5192dfd98f19 100644 --- a/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/badgedisplayedset/badgedisplaysettwo/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsBadgeDisplaySetTwoTest', function () { console.info("===========ActsDoNotDisturbModeSetTest2 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsBadgeDisplaySetTwoTest', function () { console.log("==========================>ActsBadgeDisplaySet_test_0300 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0300====>"); + }, time); }) /* * @tc.number: ActsBadgeDisplaySet_test_0400 @@ -42,6 +45,9 @@ describe('ActsAnsBadgeDisplaySetTwoTest', function () { bundle:"com.neu.actsanslocalcandisplaytest" },false).then(console.log("==========================>ActsBadgeDisplaySet_test_0400 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsBadgeDisplaySet_test_0400====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0300 @@ -56,6 +62,9 @@ describe('ActsAnsBadgeDisplaySetTwoTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0300====>"); + }, time); }) /* * @tc.number: ActsSystemCanDisplaySet_test_0400 @@ -70,6 +79,9 @@ describe('ActsAnsBadgeDisplaySetTwoTest', function () { console.log("==========================>ActsSystemCanDisplaySet_test_0400 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemCanDisplaySet_test_0400====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/Test.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/Test.json index f846b039485e4869d1ecbc363fe179e8c43b77de..461948f147bb7b2533b9a1c61b5981ad5bbb0ab1 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationfivetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/package.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js index 584a1b8654a5d7998b6aaa46920d6335e69149e5..cfcba68c66e39c1084bef5fe0a8b03b74e6ad4f2 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationFiveTest', function () { console.info("===========ActsEnableNotificationTest5 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationFiveTest', function () { console.log("==========================>ActsEnableNotification_test_0900 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0900====>"); + }, time); }) /* * @tc.number: ActsEnableNotification_test_1000 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationFiveTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },"").then(console.log("==========================>ActsEnableNotification_test_1000 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_1000====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0900 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationFiveTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0900====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_1000 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationFiveTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotification_test_1000 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_1000====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/Test.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/Test.json index 5acd3b28a8c393454ba33853e339a4e69d493461..e792043f2ed024c43ce7fef04a44e7e1120471cc 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationfourtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/package.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js index 671315b69dfa0dc569b0ba9ec1ff4eea2c999359..f55242b9bd564034f2ee4d0e21cf7c54b2328084 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationFourTest', function () { console.info("===========ActsEnableNotificationTest4 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationFourTest', function () { console.log("==========================>ActsEnableNotification_test_0700 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0700====>"); + }, time); }) /* * @tc.number: ActsEnableNotification_test_0800 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationFourTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },100).then(console.log("==========================>ActsEnableNotification_test_0800 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0800====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0700 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationFourTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0700====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0800 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationFourTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotification_test_0800 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0800====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationone/Test.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationone/Test.json index 0638a8b93e54197de26e4a3a129c787a4415f07a..ada1906daad7c0706d3800bcf3de4c1d8bfa4a11 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationone/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationone/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationonetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/package.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js index 13c278eb3c166816a48d8df03e057dc8338ee634..5d3c8403810a67d0de6d647af52258f03e3ecd70 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationOneTest', function () { console.info("===========ActsEnableNotificationTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationOneTest', function () { console.log("==========================>ActsEnableNotification_test_0100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0100====>"); + }, time); }) /* * @tc.number: ActsEnableNotification_test_0200 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationOneTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },true).then(console.log("==========================>ActsEnableNotification_test_0200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0200====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0100 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationOneTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0100====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0200 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationOneTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotification_test_0200 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/Test.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/Test.json index d357e0ff7a7ef528eb843a31b2e9008a4a10a931..aab3ae7a8503025694aee0b4ad44f083503ef890 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsixtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/package.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js index d45e54319fda0e94c0ca2af6ee8b8913beadfe5e..f6d3398ba7d11c1a4eadc8b8f2f7224de6ecb24b 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSixTest', function () { console.info("===========ActsEnableNotificationTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSixTest', function () { console.log("==========================>ActsEnableNotification_test_1100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_1100====>"); + }, time); }) /* * @tc.number: ActsEnableNotification_test_1200 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSixTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },true).then(console.log("==========================>ActsEnableNotification_test_1200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_1200====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_1100 @@ -54,6 +60,9 @@ describe('ActsAnsEnableNotificationSixTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_1100====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_1200 @@ -65,6 +74,9 @@ describe('ActsAnsEnableNotificationSixTest', function () { console.log("==========================>ActsSystemNotification_test_1200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_1200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/Test.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/Test.json index bb95b4ed11723ea31c54353fbfddf407eb14ab7b..64147fdd1a2f069ce5594c373299cea6733c8a7a 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationtreetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/package.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js index d1da1d43bf2975e08684b2b32035d9e8fa8105c8..5055bc2b6d592d26ecf92d199f38ea4f30d1a0b9 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationTreeTest', function () { console.info("===========ActsEnableNotificationTest3 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationTreeTest', function () { console.log("==========================>ActsEnableNotification_test_0500 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0500====>"); + }, time); }) /* * @tc.number: ActsEnableNotification_test_0600 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationTreeTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },true).then(console.log("==========================>ActsEnableNotification_test_0600 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0600====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0500 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationTreeTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0500====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0600 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationTreeTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotification_test_0600 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0600====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/Test.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/Test.json index 2baeccde779ed65d8e871e9c0f43e41618671faa..77c6706e6acf1f64ac45344d297a3f3529a3917c 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationtwotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/package.json b/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js index 6484cbcd053f9d2fac6537497200efc99056d4e5..0370e0b3ef7df010a693cf6590b33bda2c960cc3 100644 --- a/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotification/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationTwoTest', function () { console.info("===========ActsEnableNotificationTest2 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationTwoTest', function () { console.log("==========================>ActsEnableNotification_test_0300 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0300====>"); + }, time); }) /* * @tc.number: ActsEnableNotification_test_0400 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationTwoTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },false).then(console.log("==========================>ActsEnableNotification_test_0400 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotification_test_0400====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0300 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationTwoTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0300====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0400 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationTwoTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotification_test_0400 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotification_test_0400====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotification/localnotificationenable/Test.json b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/Test.json index ef6d46bdbc17ecb3a8b3d4db1f8488a403384159..5248d49eef03ba3f032249156ccca7cb4b587927 100644 --- a/notification/ans_standard/publish_test/enablenotification/localnotificationenable/Test.json +++ b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanslocalnotificationtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/.gitignore b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..3543521e9fef8e7322940a87c2b45dd0061b0f45 --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/.gitignore @@ -0,0 +1 @@ +/build diff --git a/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/package.json b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/src/main/js/test/LocalNotificationEnable.js b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/src/main/js/test/LocalNotificationEnable.js index e97c6b7944b82ed324d1a75a1e8242a5fec3771a..027304cce0b69931ce5331c92cc48a8024b819af 100644 --- a/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/src/main/js/test/LocalNotificationEnable.js +++ b/notification/ans_standard/publish_test/enablenotification/localnotificationenable/entry/src/main/js/test/LocalNotificationEnable.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsLocalNotificationTest', function () { console.info("===========ActsLocalNotificationTest start====================>"); /* @@ -29,6 +29,9 @@ describe('ActsAnsLocalNotificationTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsLocalNotification_test_0100====>"); + }, time); }) /* * @tc.number: ActsLocalNotification_test_0200 @@ -40,6 +43,9 @@ describe('ActsAnsLocalNotificationTest', function () { console.log("==========================>ActsLocalNotification_test_0200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsLocalNotification_test_0200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/Test.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/Test.json index a2aca000f6b48feaeb820c5c10f37312aae4589a..6d983960d52ca7ec11e70ca87c747a65d3657364 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/Test.json +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsetfivetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/package.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js index 8e3bdfce3f971ddb266b2942efdf522acbbd8f87..bbcc27867049277ab4469af79400f12862979bf6 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfive/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSetFiveTest', function () { console.info("===========ActsEnableNotificationSetTest5 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSetFiveTest', function () { console.log("==========================>ActsEnableNotificationSet_test_0900 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0900====>"); + }, time); }) /* * @tc.number: ActsEnableNotificationSet_test_1000 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSetFiveTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },"").then(console.log("==========================>ActsEnableNotificationSet_test_1000 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_1000====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0900 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationSetFiveTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0900====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_1000 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationSetFiveTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotificationSet_test_1000 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_1000====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/Test.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/Test.json index 6075d5ab8905bb4f8a744bf245b57adad5206b52..c33a27546fbb48f6d3ab3674a01e50384ec72aad 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/Test.json +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsetfourtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/package.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js index d7cc51e58b582a8a9e02142d22f80075b64b118c..a983e523537788b6e22c5747f00bd209a56b05d9 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationfour/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSetFourTest', function () { console.info("===========ActsEnableNotificationSetTest4 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSetFourTest', function () { console.log("==========================>ActsEnableNotificationSet_test_0700 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0700====>"); + }, time); }) /* * @tc.number: ActsEnableNotificationSet_test_0800 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSetFourTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },100).then(console.log("==========================>ActsEnableNotificationSet_test_0800 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0800====>"); + }, time); }) /* * @tc.number: ActsSystemNotification_test_0700 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationSetFourTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0700====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0800 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationSetFourTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotificationSet_test_0800 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0800====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/Test.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/Test.json index 4bf47edc7fb46c14fc81a3d319597035f7ff7bb5..bfdc4b7e90486e8ce3a8b0c2ec2de9f08dad08ab 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/Test.json +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsetonetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/package.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js index e2b799855e1b1bf51290d67405cd830238c9eec9..cf685dfef9c6905ca4687324783b1b5c4abb289e 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationone/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSetOneTest', function () { console.info("===========ActsEnableNotificationSetTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSetOneTest', function () { console.log("==========================>ActsEnableNotificationSet_test_0100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0100====>"); + }, time); }) /* * @tc.number: ActsEnableNotificationSet_test_0200 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSetOneTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },true).then(console.log("==========================>ActsEnableNotificationSet_test_0200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0200====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0100 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationSetOneTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0100====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0200 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationSetOneTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotificationSet_test_0200 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/Test.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/Test.json index f79e790a0f6e63b84abb2a2b815310ffce8665ff..0f45043fdf432e3a47d7df00df2b4ce7e42157f0 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/Test.json +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsetsixtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/package.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js index 3201a951370f04b4e2d72abffa0eec518097e985..9f163c87832fcf6a9963357b113e28665c325804 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationsix/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSetSixTest', function () { console.info("===========ActsEnableNotificationSetTest1 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSetSixTest', function () { console.log("==========================>ActsEnableNotificationSet_test_1100 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_1100====>"); + }, time); }) /* * @tc.number: ActsEnableNotificationSet_test_1200 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSetSixTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },true).then(console.log("==========================>ActsEnableNotificationSet_test_1200 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_1200====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_1100 @@ -54,6 +60,9 @@ describe('ActsAnsEnableNotificationSetSixTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_1100====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_1200 @@ -65,6 +74,9 @@ describe('ActsAnsEnableNotificationSetSixTest', function () { console.log("==========================>ActsSystemNotificationSet_test_1200 success=======================>"+promise) expect(typeof(promise)).assertEqual('boolean') done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_1200====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/Test.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/Test.json index ed062c9e677400386e93ad334ab4e049d6f539ca..6d53778a7fa35576da93b397dbea78b09a2de215 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/Test.json +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsettreetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/package.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js index 8e1789fa95f14132e9b8a980275431fa1b558dc5..127d1a32fb99c622c63fc462441b06293d4549c6 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtree/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSetTreeTest', function () { console.info("===========ActsEnableNotificationSetTest3 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSetTreeTest', function () { console.log("==========================>ActsEnableNotificationSet_test_0500 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0500====>"); + }, time); }) /* * @tc.number: ActsEnableNotificationSet_test_0600 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSetTreeTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },true).then(console.log("==========================>ActsEnableNotificationSet_test_0600 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0600====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0500 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationSetTreeTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0500====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0600 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationSetTreeTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotificationSet_test_0600 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0600====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/Test.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/Test.json index 6ead31b796a0a4e596a5099f6c54e6e318874a5f..7d73eb8823ba8ee72606fc6fc9430fae0da808e2 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/Test.json +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansenablenotificationsettwotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/package.json b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js index 5285b0ce3f9019476cea2c093501706e42d29426..febf45579ee4ff6c13ba5ad363e983dad2525936 100644 --- a/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js +++ b/notification/ans_standard/publish_test/enablenotificationset/enablenotificationtwo/entry/src/main/js/test/BadgeDisplay.js @@ -15,7 +15,7 @@ import notify from '@ohos.notification' import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - +var time = 1000 describe('ActsAnsEnableNotificationSetTwoTest', function () { console.info("===========ActsEnableNotificationSetTest2 start====================>"); /* @@ -30,6 +30,9 @@ describe('ActsAnsEnableNotificationSetTwoTest', function () { console.log("==========================>ActsEnableNotificationSet_test_0300 success=======================>"+err) }) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0300====>"); + }, time); }) /* * @tc.number: ActsEnableNotificationSet_test_0400 @@ -42,6 +45,9 @@ describe('ActsAnsEnableNotificationSetTwoTest', function () { bundle:"com.neu.actsanslocalnotificationtest", },false).then(console.log("==========================>ActsEnableNotificationSet_test_0400 success=======================>")) done(); + setTimeout(function(){ + console.debug("====>time out ActsEnableNotificationSet_test_0400====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0300 @@ -56,6 +62,9 @@ describe('ActsAnsEnableNotificationSetTwoTest', function () { expect(typeof(data)).assertEqual('boolean') }) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0300====>"); + }, time); }) /* * @tc.number: ActsSystemNotificationSet_test_0400 @@ -70,6 +79,9 @@ describe('ActsAnsEnableNotificationSetTwoTest', function () { expect(typeof(promise)).assertEqual('boolean') console.log("==========================>ActsSystemNotificationSet_test_0400 success=======================>"+promise) done(); + setTimeout(function(){ + console.debug("====>time out ActsSystemNotificationSet_test_0400====>"); + }, time); }) }) diff --git a/notification/ans_standard/publish_test/getactive/BUILD.gn b/notification/ans_standard/publish_test/getactive/BUILD.gn deleted file mode 100644 index 60a230cf9217cb09fa53b91ba047cb391b88ec8f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/BUILD.gn +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -group("getactive") { - testonly = true - if (is_standard_system) { - deps = [ - "getactivenormal:getactivenormal", - "getcancelactivenum:ActsAnsGetCancelActiveNumTest", - ] - } -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/BUILD.gn b/notification/ans_standard/publish_test/getactive/getactivenormal/BUILD.gn deleted file mode 100644 index 975f4301e1de0f0d7ea99eee1c94df0fae3c369c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/BUILD.gn +++ /dev/null @@ -1,26 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -group("getactivenormal") { - testonly = true - if (is_standard_system) { - deps = [ - "active:ActsAnsGetActiveTest", - - # "sub:ActsAnsActiveSubscriberTest", - "publish:ActsAnsActivePublishTest", - ] - } -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/BUILD.gn b/notification/ans_standard/publish_test/getactive/getactivenormal/active/BUILD.gn deleted file mode 100644 index e244dcb6447df0f9e15d22c46aad00918c380582..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsGetActiveTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsGetActiveTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/Test.json b/notification/ans_standard/publish_test/getactive/getactivenormal/active/Test.json deleted file mode 100644 index 764df08e35ce8a941967a1da9ff1ce76fcdb5ca9..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansgetactivetest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsGetActiveTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/config.json b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/config.json deleted file mode 100644 index 3d323e181c539a7aa28aa9cc660f4d9b98953de3..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansgetactivetest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansgetactivetest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansgetactivetest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 8e5bbd698cf7316754b1666319656dfd7bae644f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - active程序启动 - -
diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 55a7f240d259f83a1ceddc76d3c5def91aee2308..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "Active" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/test/GetActiveInfo.test.js b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/test/GetActiveInfo.test.js deleted file mode 100644 index 667f8f6c7d00405fa26ac75245da632ea9a6e191..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/test/GetActiveInfo.test.js +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import notify from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsGetActiveTest', function () { - console.info("===========ActsSubscriberTest start====================>"); - - /* - * @tc.number: ActsActive_test_0100 - * @tc.name: getAllActiveNotifications() - * @tc.desc: verify the function of getAllActiveNotifications - */ - it('ActsActive_test_0100', 0, async function (done) { - await notify.getAllActiveNotifications((error, data) => { - console.log("==========================>getAllActiveNotifications1=======================>" + data) - expect(typeof(data)).assertEqual('object') - for (let i = 0; i < data.length; i++) { - console.log("==========================>getAllActiveNotificationshashCode1=======================>" + data[i].hashCode) - console.log("==========================>getAllActiveNotificationsid1=======================>" + data[i].id) - console.log("==========================>getAllActiveNotificationslotType1=======================>" + data[i].slotType) - console.log("==========================>getAllActiveNotificationclassification1=======================>" + data[i].classification) - console.log("==========================>getAllActiveNotificationsortingKey1=======================>" + data[i].sortingKey) - console.log("==========================>getAllActiveNotificationscontentType1=======================>" + data[i].content.contentType) - console.log("==========================>getAllActiveNotificationstitle1=======================>" + data[i].content.normal.title) - console.log("==========================>getAllActiveNotificationstext1=======================>" + data[i].content.normal.text) - console.log("==========================>getAllActiveNotificationsadditionalText1=======================>" + data[i].content.normal.additionalText) - } - }) - - var promise = await notify.getAllActiveNotifications() - expect(typeof(promise)).assertEqual('object') - for (let i = 0; i < promise.length; i++) { - console.log("==========================>getAllActiveNotificationsPromisehashCode1=======================>" + promise[i].hashCode) - console.log("==========================>getAllActiveNotificationsPromiseid1=======================>" + promise[i].id) - console.log("==========================>getAllActiveNotificationsPromiseslotType1=======================>" + promise[i].slotType) - console.log("==========================>getAllActiveNotificationsPromiseclassification1=======================>" + promise[i].classification) - console.log("==========================>getAllActiveNotificationsPromisesortingKey1=======================>" + promise[i].sortingKey) - console.log("==========================>getAllActiveNotificationsPromisecontentType1=======================>" + promise[i].content.contentType) - console.log("==========================>getAllActiveNotificationsPromisetitle1=======================>" + promise[i].content.normal.title) - console.log("==========================>getAllActiveNotificationsPromisetext1=======================>" + promise[i].content.normal.text) - console.log("==========================>getAllActiveNotificationsPromiseadditionalText1=======================>" + promise[i].content.normal.additionalText) - } - done(); - }) - -}) - diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/test/List.test.js deleted file mode 100644 index 36f3624a07c34f04eaac62fab64814215be2fd18..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/active/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./GetActiveInfo.test.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/active/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/getactive/getactivenormal/active/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getactivenormal/active/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/BUILD.gn b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/BUILD.gn deleted file mode 100644 index 1ce0eb7222a98988859964c7ea8995c7983a8333..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsActivePublishTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsActivePublishTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/Test.json b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/Test.json deleted file mode 100644 index 35324d67fa5fdb5158c594fbbef9ea3184135b4c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansactivepublishtest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsActivePublishTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/config.json b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/config.json deleted file mode 100644 index 10b5c3b052989b7a4a1036e97ba3851230434b88..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansactivepublishtest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansactivepublishtest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansactivepublishtest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index fc2437b2b0af5bd75dfc14e0ea743d011159ede3..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 发布接口调用 - -
diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index a83a041be69ed1ded7913caee6fa1906315c41a0..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "publish1" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index 0fc7d96fcb0a343f11f6d18e9303d673d1939c28..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsActivePublishTest', function () { - function publishCallback001(){ - console.log('ActsNotificationTest ACTS_Publish_0100 asyncCallback') - } - - /* - * @tc.number: ACTS_GetActiveNumTest_0100 - * @tc.name: getActiveNotifications(),getActiveNotificationNums() - * @tc.desc: verify the function of getActiveNotifications,getActiveNotificationNums - */ - it('ACTS_GetActiveNumTest_0100', 0,async function (done) { - await notification.publish({ - id: 1, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test1_title", - text: "test1_text", - additionalText: "test1_additionalText" - }, - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION, - classification:"classification1", - sortingKey:"sortingKey1", - },publishCallback001); - await notification.publish({ - id: 2, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test2_title", - text: "test2_text", - additionalText: "test2_additionalText" - }, - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION, - classification:"classification2", - sortingKey:"sortingKey2", - },publishCallback001); - - await notification.getActiveNotifications( - (error,data) => { - console.log("============PublishgetActiveNotificationsTest1============"+data) - expect(typeof(data)).assertEqual('object') - for (let i = 0; i < data.length; i++) { - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].hashCode) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].id) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].classification) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].sortingKey) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].slotType) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].content.contentType) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].content.normal.title) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].content.normal.text) - console.log("==========================>PublishgetActiveNotificationsTest1=======================>" + data[i].content.normal.additionalText) - } - }) - - var promise = await notification.getActiveNotifications(); - expect(typeof(promise)).assertEqual('object') - for (let i = 0; i < promise.length; i++) { - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].hashCode) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].id) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].slotType) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].classification) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].sortingKey) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.contentType) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.normal.title) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.normal.text) - console.log("==========================>publishgetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.normal.additionalText) - } - - await notification.getActiveNotificationNums((error,data) => { - console.log("============getActiveNotificationNumsTest1============"+JSON.stringify(data)) - expect(typeof(data)).assertEqual('number') - }) - - var promise = await notification.getActiveNotificationNums(); - console.log("============getActiveNotificationNumsTest1Promise============"+JSON.stringify(promise)) - console.log("============ACTS_PublishTest1_0100 finished============") - expect(typeof(promise)).assertEqual('number') - done(); - }) -}) \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/getactive/getactivenormal/publish/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getactivenormal/publish/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/BUILD.gn b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/BUILD.gn deleted file mode 100644 index 19f81bfe930bef22db042d0c7b1258521c0ff739..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsActiveSubscriberTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsActiveSubscriberTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/Test.json b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/Test.json deleted file mode 100644 index ff7ba7389c0ca0c8cd55ff07a43a52c3e4972f71..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansactivesubscribertest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsActiveSubscriberTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/config.json b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/config.json deleted file mode 100644 index 38ceab0b83f034b4fcc5f84dd7ef9199e388791c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansactivesubscribertest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansactivesubscribertest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansactivesubscribertest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 0ac24eaf6f6b6e2b1ff1f01dc0c724b2692299c5..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 订阅程序1启动 - -
diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 6d530caefcdbe79f49db0b49fb864ed4daaeaac0..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "Sub1" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/test/List.test.js deleted file mode 100644 index 41999288d49304127387014dc88894130a148ab4..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./Subscriber.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/test/Subscriber.js b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/test/Subscriber.js deleted file mode 100644 index 9a91aa9adf98fe114b2ed0e047921005e2ce898f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/entry/src/main/js/test/Subscriber.js +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import notify from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsActiveSubscriberTest', function () { - console.info("===========ActsSubscriberTest start====================>"); - - //consume - function consumeCallback(err, data) { - console.debug("==========================>consumeCallback data : =======================>" + JSON.stringify(data)); - } - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeCallback=======================>"); - } - - /* - * @tc.number: ActsWantAgent_test_0100 - * @tc.name: createSubscriber(),subscribe() - * @tc.desc: verify the function of createSubscriber,subscribe - */ - it('ActsActiveSubscriber_test_0100', 0, async function (done) { - console.debug("===============ActsWantAgent_test_0100======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallback, - onConnected:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - }catch(err) { - console.error('=ActsActiveSubscriber_test_0100 订阅 subscribeCallback err:'+err); - } - console.debug("===============ActsActiveSubscriber_test_0100=======end===================>"); - done(); - }) -}) - diff --git a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/getactive/getactivenormal/sub/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getactivenormal/sub/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/BUILD.gn b/notification/ans_standard/publish_test/getactive/getcancelactivenum/BUILD.gn deleted file mode 100644 index 4c8b8a239aa508386a7a21375c99c0edbe866043..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsGetCancelActiveNumTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsGetCancelActiveNumTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/Test.json b/notification/ans_standard/publish_test/getactive/getcancelactivenum/Test.json deleted file mode 100644 index a63be05e9fba87e37e1f1d543466c550f6a1d489..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansgetcancelactivenumtest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsGetCancelActiveNumTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/config.json b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/config.json deleted file mode 100644 index fdfef954b2f394f8a094b5edb2b02117636e6537..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansgetcancelactivenumtest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansgetcancelactivenumtest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansgetcancelactivenumtest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 4a5287619f9cfd05dd47ad8bc78fe606a254d45b..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - GetCancelActiveNum启动 - -
diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 2d0b6a30c006e4468343aef65f7e168626226f72..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "CancelActiveNum" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/test/GetCancelActiveNum.test.js b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/test/GetCancelActiveNum.test.js deleted file mode 100644 index 0a59767febf9a48fe2ce18974934bb850cc2a6f9..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/test/GetCancelActiveNum.test.js +++ /dev/null @@ -1,167 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import notify from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsGetCancelActiveNumTest', function () { - console.info("===========ActsGetCancelActiveNumTest start====================>"); - - //consume - function consumeCallback(err, data) { - console.debug("==========================>consumeCallback data : =======================>" + JSON.stringify(data)); - console.debug("==========================>consumeCallback===notificationId:====================>" + data.request.id); - console.debug("==========================>consumeCallback===sortingMap.sortedHashCode.length:====================>" + data.sortingMap.sortedHashCode.length); - } - - function cancelAllCallBack(){ - console.info("==========================>cancelAllCallBack start=======================>"); - } - - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeCallback=======================>"); - - } - //publish - function publishCallback001(){ - console.log('ActsAnsGetCancelActiveNumTest ActsGetCancelActiveNum_test_0200 publish asyncCallback') - } - - /* - * @tc.number: ActsGetCancelActiveNum_test_0100 - * @tc.name: createSubscriber(),subscriber() - * @tc.desc: verify the function of createSubscriber,subscriber - */ - it('ActsGetCancelActiveNum_test_0100', 0, async function (done) { - console.debug("===============ActsGetCancelActiveNum_test_0100======begin====================>"); - var subInfo ={ - onConsumed:consumeCallback, - onConnected:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - }catch(err) { - console.error('=ActsWantAgent_test_0100 订阅 subscribeCallback err:'+err); - } - console.debug("===============ActsGetCancelActiveNum_test_0100=======end===================>"); - done(); - }) - - /* - * @tc.number: ActsGetCancelActiveNum_test_0200 - * @tc.name: getActiveNotifications(),getActiveNotificationNums() - * @tc.desc: verify the function of getActiveNotifications,getActiveNotificationNums - */ - it('ActsGetCancelActiveNum_test_0200', 0,async function (done) { - await notify.publish({ - id: 1, - content: { - contentType: notify.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test1_title", - text: "test1_text", - additionalText: "test1_additionalText" - }, - } - },publishCallback001); - await notify.publish({ - id: 2, - content: { - contentType: notify.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test2_title", - text: "test2_text", - additionalText: "test2_additionalText" - }, - } - },publishCallback001); - await notify.publish({ - id: 3, - content: { - contentType: notify.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test3_title", - text: "test3_text", - additionalText: "test3_additionalText" - }, - } - },publishCallback001); - - await notify.getActiveNotifications( - (error,data) => { - console.log("============PublishGetActiveNotificationsTest1============"+data) - expect(typeof(data)).assertEqual('object') - for (let i = 0; i < data.length; i++) { - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].hashCode) - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].Id) - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].slotType) - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].content.contentType) - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].content.normal.title) - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].content.normal.text) - console.log("==========================>PublishGetActiveNotificationsTest1=======================>" + data[i].content.normal.additionalText) - } - }) - - var promise = await notify.getActiveNotifications(); - expect(typeof(promise)).assertEqual('object') - for (let i = 0; i < promise.length; i++) { - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].hashCode) - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].Id) - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].slotType) - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.contentType) - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.normal.title) - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.normal.text) - console.log("==========================>publishGetAllActiveNotificationsPromisehashCode=======================>" + promise[i].content.normal.additionalText) - } - - await notify.getActiveNotificationNums((error,data) => { - console.log("============getActiveNotificationNumsTest1============"+JSON.stringify(data)) - expect(typeof(data)).assertEqual('number') - }) - - var promise = await notify.getActiveNotificationNums(); - expect(typeof(promise)).assertEqual('number') - console.log("============getActiveNotificationNumsTest1Promise============"+JSON.stringify(promise)) - console.log("============ActsGetCancelActiveNum_test_0200 finished============") - done(); - }) - - /* - * @tc.number: ActsGetCancelActiveNum_test_0300 - * @tc.name: cancel(),getActiveNotificationNums() - * @tc.desc: verify the function of cancel,getActiveNotificationNums - */ - it('ActsGetCancelActiveNum_test_0300', 0,async function (done) { - - await notify.cancel(1,cancelAllCallBack); - - await notify.getActiveNotificationNums((error,data) => { - expect(typeof(data)).assertEqual('number') - console.log("============getActiveNotificationCancelNums============"+JSON.stringify(data)) - }) - - var promise = await notify.getActiveNotificationNums(); - expect(typeof(promise)).assertEqual('number') - console.log("============getActiveNotificationCancelNumsPromise============"+JSON.stringify(promise)) - console.log("============ActsGetCancelActiveNum_test_0300 finished============") - done(); - }) -}) - diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/test/List.test.js deleted file mode 100644 index 5500d70bae42c3eeb4b53873a4b8052b553817ee..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/getactive/getcancelactivenum/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./GetCancelActiveNum.test.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/getactive/getcancelactivenum/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/getactive/getcancelactivenum/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/getactive/getcancelactivenum/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/Test.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/Test.json index 0e6c3d42aeb2020cfa48a4559ee927992f12fcfa..6b213ca8fc72246d7319658495ae19069fd627c4 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/Test.json +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansgetwantagentinfoonetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/package.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/src/main/js/test/WantAgent.test.js index b66f9611114be72dc3e003b2f3708274dd4f4937..10586fcde32907fe496926f52fd0a5bb7ae58a6a 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoone/entry/src/main/js/test/WantAgent.test.js @@ -19,7 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from ' var WantAgent1; var WantAgent2; - +var time = 1000 describe('ActsAnsGetWantAgentInfoOneTest', function () { console.info('----ActsGetWantAgentInfoTest----'); /* @@ -103,6 +103,9 @@ describe('ActsAnsGetWantAgentInfoOneTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0100====>"); + }, time); }), console.info('----getWantAgent1 after----'); }) @@ -180,6 +183,9 @@ describe('ActsAnsGetWantAgentInfoOneTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0200====>"); + }, time); }); console.info('----getWantAgent2 after----'); }) diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/Test.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/Test.json index 05e12b7738ecb412694a9bd49f7cfb726bf2b509..6acf250319c80e82712a05b0f69383806b42c05c 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/Test.json +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansgetwantagentinfooneprotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/package.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/src/main/js/test/WantAgent.test.js index 2db960cad02101e1c50494ebee876298c4d3e3f2..c3587a8dd3e48f6f226ce912d1cca7d571016c5f 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfoonepro/entry/src/main/js/test/WantAgent.test.js @@ -19,6 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from ' var WantAgent1; var WantAgent2; +var time = 1000 describe('ActsAnsGetWantAgentInfoOneProTest', function () { console.info('----ActsGetWantAgentInfoTest----'); /* @@ -95,6 +96,9 @@ describe('ActsAnsGetWantAgentInfoOneProTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0300====>"); + }, time) }), console.info('----getWantAgent1 after----'); }) @@ -162,6 +166,9 @@ describe('ActsAnsGetWantAgentInfoOneProTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0400====>"); + }, time) }); console.info('----getWantAgent2 after----'); }) diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/Test.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/Test.json index 998d7b412ec4e538d9736739d10437b98db4ba18..f52b50841265f44645f21a632220ff5175555533 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/Test.json +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansgetwantagentinfotwotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/package.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/src/main/js/test/WantAgent.test.js index 0c4c75cf1b4519013e72c3283e7747dfe82adad6..c28443d3f77d564e5e716bd4e24f22876636069d 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwo/entry/src/main/js/test/WantAgent.test.js @@ -19,6 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from ' var WantAgent1; var WantAgent2; +var time = 1000 describe('ActsAnsGetWantAgentInfoTwoTest', function () { console.info('----ActsGetWantAgentInfoTest----'); @@ -75,6 +76,9 @@ describe('ActsAnsGetWantAgentInfoTwoTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0500====>"); + }, time) }), console.info('----getWantAgent1 after----'); }) @@ -150,6 +154,9 @@ describe('ActsAnsGetWantAgentInfoTwoTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0600====>"); + }, time) }); console.info('----getWantAgent2 after----'); }) diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/Test.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/Test.json index 6dc2755c62c88b53d42f342c3ada6da44049a7ff..d8b11ca7f0e40da41d9e626abd228e070a201ac8 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/Test.json +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansgetwantagentinfotwoprotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/package.json b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/src/main/js/test/WantAgent.test.js index e87cb23a8948c1c9009c4200d2db263397305a29..876a7abe4896bc3c0d829e38c16569bf079e76fa 100644 --- a/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/getwantagentinfo/getwantagentinfotwopro/entry/src/main/js/test/WantAgent.test.js @@ -19,6 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from ' var WantAgent1; var WantAgent2; +var time = 1000 describe('ActsAnsGetWantAgentInfoTwoProTest', function () { console.info('----ActsGetWantAgentInfoTest----'); /* @@ -69,6 +70,9 @@ describe('ActsAnsGetWantAgentInfoTwoProTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0700====>"); + }, time) }), console.info('----getWantAgent1 after----'); }) @@ -136,6 +140,9 @@ describe('ActsAnsGetWantAgentInfoTwoProTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWantInfo_0800====>"); + }, time) }); console.info('----getWantAgent2 after----'); }) diff --git a/notification/ans_standard/publish_test/publishcontentype/BUILD.gn b/notification/ans_standard/publish_test/publishcontentype/BUILD.gn deleted file mode 100644 index 08c6cff2ad0da28da79d75e8dfe432081083f3c6..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/BUILD.gn +++ /dev/null @@ -1,30 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsNotificationTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsNotificationTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/publishcontentype/Test.json b/notification/ans_standard/publish_test/publishcontentype/Test.json deleted file mode 100644 index e8c76a7ea3155d211a5f47ae50555b22d7abf4f7..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "60000", - "package": "com.example.actsansnotificationtest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsNotificationTest" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/config.json b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/config.json deleted file mode 100644 index 242abd2cb083f4ee5063fb77d281228c932ad3e8..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansnotificationtest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansnotificationtest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansnotificationtest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index aa3c315a654f57cc17e475108f24b775d5d559d1..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - contentType - -
diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index e95e981b01b0db8c7b3b033a7cb790815eb09abd..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "ContentType" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index b168397112f67a3a2196190bb566c522965e906d..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,1102 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' -var comsumData -describe('ActsAnsNotificationTest', function () { - function publishMULTILINEContentCallback001(error){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent_0100 asyncCallback'+JSON.stringify(error.code)) - } - function publishMULTILINEContentCallback002(error){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent_0200 asyncCallback'+JSON.stringify(error.code)) - } - function publishMULTILINEContentCallback003(error){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent_0300 asyncCallback'+JSON.stringify(error.code)) - } - function publishLONGContentCallback001(error){ - console.log('ActsNotificationTest ACTS_PublishLONGContent_0100 asyncCallback'+JSON.stringify(error.code)) - } - function publishLONGContentCallback002(error){ - console.log('ActsNotificationTest ACTS_PublishLONGContent_0200 asyncCallback'+JSON.stringify(error.code)) - } - function publishLONGContentCallback003(error){ - console.log('ActsNotificationTest ACTS_PublishLONGContent_0300 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotTypeContentCallback001(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeContent_0100 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotTypeContentCallback002(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeContent_0200 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotTypeContentCallback003(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeContent_0300 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotTypeContentCallback004(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeContent_0400 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotOtherCallback001(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeOther_0100 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotOtherCallback002(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeOther_0200 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotOtherCallback003(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeOther_0300 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotOtherCallback004(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeOther_0400 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotServiceCallback001(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0100 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotServiceCallback002(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0200 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotServiceCallback003(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0300 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotServiceCallback004(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0400 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotSocialCallback001(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0400 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotSocialCallback002(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0400 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotSocialCallback003(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0400 asyncCallback'+JSON.stringify(error.code)) - } - function publishSlotSocialCallback004(error){ - console.log('ActsNotificationTest ACTS_Publish_SlotTypeService_0400 asyncCallback'+JSON.stringify(error.code)) - } - //consume - function consumeCallback(err,data) { - console.debug("==========================>consumeDoNotCallback1 data : =======================>" + err + JSON.stringify(data)); - comsumData = data - } - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeDoNotOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeDoNotCallback=======================>"); - } - /* - * @tc.number: ActsDoNotSubscriber_test_0100 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0100', 0, async function (done) { - console.debug("===============ActsDoNotSubscriber_test_0100======begin====================>"); - - var subInfo ={ - onConsume:consumeCallback, - onConnecte:subscribeOnCallback, - } - try { - await notification.subscribe(subInfo, subscribeCallback); - } - catch(err) { - console.error('ActsSubscriber_test_0100 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0100=======end3===================>"); - done(); - }) - - /* - * @tc.number: ACTS_PublishMULTILINEContent_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_MULTILINE) - */ - it('ACTS_PublishMULTILINEContent_0100', 0,async function (done) { - try { - await notification.publish({ - Id: 1, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_MULTILINE, - multiLine: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - briefText: "briefText", - longTitle: "longTitle", - lines: ["123", "234", "345", "456"] - }, - } - }, publishMULTILINEContentCallback001); - }catch(error){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent_0100 asyncCallback'+JSON.stringify(error.code))} - console.log("============ACTS_PublishMULTILINEContent_0100 finished============") - expect(comsumData.id).assertEqual(1) - done(); - }) - - /* - * @tc.number: ACTS_PublishMULTILINEContent_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish() - */ - it('ACTS_PublishMULTILINEContent_0200', 0,async function (done) { - try { - var notificationInfo = { - Id: 2, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_MULTILINE, - multiLine: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - briefText: "briefText", - longTitle: "longTitle", - lines: ["123", "234", "345", "456"] - }, - } - } - }catch(err){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent11111111'+err) - } - try{ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent222222222222') - await notification.publish(notificationInfo,publishMULTILINEContentCallback002); - }catch(error){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent_0200 asyncCallback'+error) - } - console.log("============ACTS_PublishMULTILINEContent_0200 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishMULTILINEContent_0300 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_PICTURE) - */ - it('ACTS_PublishMULTILINEContent_0300', 0,async function (done) { - try { - await notification.publish({ - Id: 3, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_PICTURE, - multiLine: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - briefText: "briefText", - longTitle: "longTitle", - lines: ["123", "234", "345", "456"] - }, - } - }, publishMULTILINEContentCallback003); - }catch(error){ - console.log('ActsNotificationTest ACTS_PublishMULTILINEContent_0300 asyncCallback'+JSON.stringify(error.code)) - } - console.log("============ACTS_PublishMULTILINEContent_0300 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishMULTILINEContent_0400 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_MULTILINE) promise - */ - it('ACTS_PublishMULTILINEContent_0400', 0,async function (done) { - await notification.publish({ - Id: 4, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_MULTILINE, - multiLine: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - briefText:"briefText", - longTitle:"longTitle", - lines:["123","234","345","456"] - }, - } - }).then(console.log("============ACTS_PublishMULTILINEContent_0400 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishMULTILINEContent_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish() promise - */ - it('ACTS_PublishMULTILINEContent_0500', 0,async function (done) { - await notification.publish({ - Id: 5, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_MULTILINE, - multiLine: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - briefText:"briefText", - longTitle:"longTitle", - lines:["123","234","345","456"] - }, - } - }).then(console.log("============ACTS_PublishMULTILINEContent_0500 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishMULTILINEContent_0600 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_PICTURE) promise - */ - it('ACTS_PublishMULTILINEContent_0600', 0,async function (done) { - await notification.publish({ - Id: 6, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_PICTURE, - multiLine: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - briefText:"briefText", - longTitle:"longTitle", - lines:["123","234","345","456"] - }, - } - }).then(console.log("============ACTS_PublishMULTILINEContent_0300 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishLONGContent_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_LONG_TEXT) - */ - it('ACTS_PublishLONGContent_0100', 0,async function (done) { - await notification.publish({ - Id: 7, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_LONG_TEXT, - longText: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText:"longText", - briefText:"briefText", - expandedTitle:"expandedTitle" - }} - },publishLONGContentCallback001); - console.log("============ACTS_PublishLONGContent_0100 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishLONGContent_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish() - */ - it('ACTS_PublishLONGContent_0200', 0,async function (done) { - await notification.publish({ - Id: 8, - content: { -// contentType: notification.ContentType.NOTIFICATION_CONTENT_LONG_TEXT, - longText: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText:"longText", - briefText:"briefText", - expandedTitle:"expandedTitle" - }} - },publishLONGContentCallback002); - console.log("============ACTS_PublishLONGContent_0200 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishLONGContent_0300 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_MEDIA) - */ - it('ACTS_PublishLONGContent_0300', 0,async function (done) { - await notification.publish({ - Id: 9, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_MEDIA, - longText: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText:"longText", - briefText:"briefText", - expandedTitle:"expandedTitle" - }} - },publishLONGContentCallback003); - console.log("============ACTS_PublishLONGContent_0300 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishLONGContent_0400 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_LONG_TEXT) promise - */ - it('ACTS_PublishLONGContent_0400', 0,async function (done) { - await notification.publish({ - Id: 10, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_LONG_TEXT, - longText: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText:"longText", - briefText:"briefText", - expandedTitle:"expandedTitle" - }} - }).then(console.log("============ACTS_PublishLONGContent_0400 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishLONGContent_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish() promise - */ - it('ACTS_PublishLONGContent_0500', 0,async function (done) { - await notification.publish({ - Id: 11, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_LONG_TEXT, - longText: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText:"longText", - briefText:"briefText", - expandedTitle:"expandedTitle" - }} - }).then(console.log("============ACTS_PublishLONGContent_0500 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishLONGContent_0600 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_MEDIA) promise - */ - it('ACTS_PublishLONGContent_0600', 0,async function (done) { - await notification.publish({ - Id: 12, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_MEDIA, - longText: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText", - longText:"longText", - briefText:"briefText", - expandedTitle:"expandedTitle" - }} - }).then(console.log("============ACTS_PublishLONGContent_0600 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:CONTENT_INFORMATION) - */ - it('ACTS_Publish_SlotTypeContent_0100', 0,async function (done) { - await notification.publish({ - Id: 13, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - slotType:notification.SlotType.CONTENT_INFORMATION - },publishSlotTypeContentCallback001); - console.log("============ACTS_Publish_SlotTypeContent_0100 finished============") - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:CONTENT_INFORMATION) - */ - it('ACTS_Publish_SlotTypeContent_0200', 0,async function (done) { - await notification.publish({ - Id: 14, - content: { -// contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - slotType:notification.SlotType.CONTENT_INFORMATION - },publishSlotTypeContentCallback002); - console.log("============ACTS_Publish_SlotTypeContent_0200 finished============") - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0300 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) - */ - it('ACTS_Publish_SlotTypeContent_0300', 0,async function (done) { - await notification.publish({ - Id: 15, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, -// slotType:notification.SlotType.CONTENT_INFORMATION - },publishSlotTypeContentCallback003); - console.log("============ACTS_Publish_SlotTypeContent_0300 finished============") - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0400 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SERVICE_INFORMATION) - */ - it('ACTS_Publish_SlotTypeContent_0400', 0,async function (done) { - await notification.publish({ - Id: 16, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - slotType:notification.SlotType.SERVICE_INFORMATION - },publishSlotTypeContentCallback004); - console.log("============ACTS_Publish_SlotTypeContent_0400 finished============") - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:CONTENT_INFORMATION) promise - */ - it('ACTS_Publish_SlotTypeContent_0500', 0,async function (done) { - notification.publish({ - Id: 17, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - slotType:notification.SlotType.CONTENT_INFORMATION - }).then( console.log("============ACTS_Publish_SlotTypeContent_0500 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0600 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:CONTENT_INFORMATION) promise - */ - it('ACTS_Publish_SlotTypeContent_0600', 0,async function (done) { - notification.publish({ - Id: 18, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - slotType:notification.SlotType.CONTENT_INFORMATION - }).then(console.log("============ACTS_Publish_SlotTypeContent_0600 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0700 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) promise - */ - it('ACTS_Publish_SlotTypeContent_0700', 0,async function (done) { - notification.publish({ - Id: 19, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - // slotType:notification.SlotType.CONTENT_INFORMATION - }).then(console.log("============ACTS_Publish_SlotTypeContent_0700 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_Publish_SlotTypeContent_0800 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SERVICE_INFORMATION) promise - */ - it('ACTS_Publish_SlotTypeContent_0800', 0,async function (done) { - notification.publish({ - Id: 20, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - } - }, - slotType:notification.SlotType.SERVICE_INFORMATION - }).then(console.log("============ACTS_Publish_SlotTypeContent_0800 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:OTHER_TYPES) - */ - it('ACTS_PublishSlotTypeOther_0100', 0,async function (done) { - await notification.publish({ - id:21, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.OTHER_TYPES - } - },publishSlotOtherCallback001); - console.log("============ACTS_PublishSlotTypeOther_0100 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:OTHER_TYPES) - */ - it('ACTS_PublishSlotTypeOther_0200', 0,async function (done) { - await notification.publish({ - id:22, - content: { -// contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.OTHER_TYPES - } - },publishSlotOtherCallback002); - console.log("============ACTS_PublishSlotTypeOther_0200 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0300 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) - */ - it('ACTS_PublishSlotTypeOther_0300', 0,async function (done) { - await notification.publish({ - id:23, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, -// slotType:notification.SlotType.OTHER_TYPES - } - },publishSlotOtherCallback003); - console.log("============ACTS_PublishSlotTypeOther_0300 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0400 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SOCIAL_COMMUNICATION) - */ - it('ACTS_PublishSlotTypeOther_0400', 0,async function (done) { - await notification.publish({ - id:24, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - },publishSlotOtherCallback004); - console.log("============ACTS_PublishSlotTypeOther_0400 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:OTHER_TYPES) promise - */ - it('ACTS_PublishSlotTypeOther_0500', 0,async function (done) { - notification.publish({ - id:25, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.OTHER_TYPES - } - }).then(console.log("============ACTS_PublishSlotTypeOther_0500 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0600 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:OTHER_TYPES) promise - */ - it('ACTS_PublishSlotTypeOther_0600', 0,async function (done) { - notification.publish({ - id:26, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.OTHER_TYPES - } - }).then(console.log("============ACTS_PublishSlotTypeOther_0600 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0700 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) promise - */ - it('ACTS_PublishSlotTypeOther_0700', 0,async function (done) { - notification.publish({ - id:27, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - // slotType:notification.SlotType.OTHER_TYPES - } - }).then(console.log("============ACTS_PublishSlotTypeOther_0700 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeOther_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SOCIAL_COMMUNICATION) promise - */ - it('ACTS_PublishSlotTypeOther_0800', 0,async function (done) { - notification.publish({ - id:28, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - }).then(console.log("============ACTS_PublishSlotTypeOther_0800 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SERVICE_INFORMATION) - */ - it('ACTS_PublishSlotTypeService_0100', 0,async function (done) { - await notification.publish({ - id:29, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - slotType:notification.SlotType.SERVICE_INFORMATION - },publishSlotServiceCallback001); - console.log("============ACTS_PublishSlotTypeService_0100 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:SERVICE_INFORMATION) - */ - it('ACTS_PublishSlotTypeService_0200', 0,async function (done) { - await notification.publish({ - Id: 30, - content: { -// contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - slotType:notification.SlotType.SERVICE_INFORMATION - },publishSlotServiceCallback002); - console.log("============ACTS_PublishSlotTypeService_0200 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0300 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) - */ - it('ACTS_PublishSlotTypeService_0300', 0,async function (done) { - await notification.publish({ - Id: 31, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, -// slotType:notification.SlotType.SERVICE_INFORMATION - },publishSlotServiceCallback003); - console.log("============ACTS_PublishSlotTypeService_0300 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0400 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:UNKNOWN_TYPE) - */ - it('ACTS_PublishSlotTypeService_0400', 0,async function (done) { - await notification.publish({ - Id: 32, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - slotType:notification.SlotType.UNKNOWN_TYPE - },publishSlotServiceCallback004); - console.log("============ACTS_PublishSlotTypeService_0400 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SERVICE_INFORMATION) promise - */ - it('ACTS_PublishSlotTypeService_0500', 0,async function (done) { - notification.publish({ - Id: 33, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - slotType:notification.SlotType.SERVICE_INFORMATION - }).then(console.log("============ACTS_PublishSlotTypeService_0500 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0600 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:SERVICE_INFORMATION) promise - */ - it('ACTS_PublishSlotTypeService_0600', 0,async function (done) { - notification.publish({ - Id: 34, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - slotType:notification.SlotType.SERVICE_INFORMATION - }).then(console.log("============ACTS_PublishSlotTypeService_0600 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0700 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) promise - */ - it('ACTS_PublishSlotTypeService_0700', 0,async function (done) { - notification.publish({ - Id: 35, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - // slotType:notification.SlotType.SERVICE_INFORMATION - }).then(console.log("============ACTS_PublishSlotTypeService_0700 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeService_0800 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:UNKNOWN_TYPE) promise - */ - it('ACTS_PublishSlotTypeService_0800', 0,async function (done) { - notification.publish({ - Id: 36, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - }, - slotType:notification.SlotType.UNKNOWN_TYPE - }).then(console.log("============ACTS_PublishSlotTypeService_0800 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SOCIAL_COMMUNICATION) - */ - it('ACTS_PublishSlotTypeSocial_0100', 0,async function (done) { - await notification.publish({ - Id: 37, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - },publishSlotSocialCallback001); - console.log("============ACTS_PublishSlotTypeSocial_0600 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:SOCIAL_COMMUNICATION) - */ - it('ACTS_PublishSlotTypeSocial_0200', 0,async function (done) { - await notification.publish({ - Id: 38, - content: { -// contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - },publishSlotSocialCallback002); - console.log("============ACTS_PublishSlotTypeSocial_0600 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0300 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) - */ - it('ACTS_PublishSlotTypeSocial_0300', 0,async function (done) { - await notification.publish({ - Id: 39, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, -// slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - },publishSlotSocialCallback003); - console.log("============ACTS_PublishSlotTypeSocial_0300 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0400 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:CONTENT_INFORMATION) - */ - it('ACTS_PublishSlotTypeSocial_0400', 0,async function (done) { - await notification.publish({ - Id: 40, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.CONTENT_INFORMATION - } - },publishSlotSocialCallback004); - console.log("============ACTS_PublishSlotTypeSocial_0400 finished============") - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0500 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:SOCIAL_COMMUNICATION) promise - */ - it('ACTS_PublishSlotTypeSocial_0500', 0,async function (done) { - notification.publish({ - Id: 41, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - }).then(console.log("============ACTS_PublishSlotTypeSocial_0500 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0600 - * @tc.name: publish() - * @tc.desc: verify the function of publish(slotType:SOCIAL_COMMUNICATION) promise - */ - it('ACTS_PublishSlotTypeSocial_0600', 0,async function (done) { - notification.publish({ - Id: 42, - content: { - // contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - }).then(console.log("============ACTS_PublishSlotTypeSocial_0600 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0700 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT) promise - */ - it('ACTS_PublishSlotTypeSocial_0700', 0,async function (done) { - notification.publish({ - Id: 43, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - // slotType:notification.SlotType.SOCIAL_COMMUNICATION - } - }).then(console.log("============ACTS_PublishSlotTypeSocial_0700 finished============")) - done(); - }) - - /* - * @tc.number: ACTS_PublishSlotTypeSocial_0800 - * @tc.name: publish() - * @tc.desc: verify the function of publish(contentType:NOTIFICATION_CONTENT_BASIC_TEXT,slotType:CONTENT_INFORMATION) promise - */ - it('ACTS_PublishSlotTypeSocial_0800', 0,async function (done) { - notification.publish({ - Id: 44, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test_title", - text: "test_text", - additionalText: "test_additionalText" - }, - slotType:notification.SlotType.CONTENT_INFORMATION - } - }).then(console.log("============ACTS_PublishSlotTypeSocial_0800 finished============")) - done(); - }) - -}) \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishcontentype/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishcontentype/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/publishcontentype/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/publishcontentype/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/publishimage/BUILD.gn b/notification/ans_standard/publish_test/publishimage/BUILD.gn deleted file mode 100644 index c54ea8d15a12e08f9c3279b1a9b9661e667f9023..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsPublishImageTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsPublishImageTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/publishimage/Test.json b/notification/ans_standard/publish_test/publishimage/Test.json deleted file mode 100644 index 58641bb3959b3e103b9cc3af6054acd4ff0c7215..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsanspublishimagetest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsPublishImageTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/config.json b/notification/ans_standard/publish_test/publishimage/entry/src/main/config.json deleted file mode 100644 index edd5e6885eb9d0e5b4980b1a028a24cccdb124f2..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsanspublishimagetest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsanspublishimagetest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsanspublishimagetest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 2a6ecfe5b683148ed02ca6c2641962f5fc4b6343..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 发布图片通知 - -
diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 276723f49226e6b64f8dfb67e779c944bc3f58f1..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "Pubimage" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/test/List.test.js deleted file mode 100644 index 41999288d49304127387014dc88894130a148ab4..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./Subscriber.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/test/Subscriber.js b/notification/ans_standard/publish_test/publishimage/entry/src/main/js/test/Subscriber.js deleted file mode 100644 index e7b942978b46dd0425ea9012eafb090c8127cc22..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/publishimage/entry/src/main/js/test/Subscriber.js +++ /dev/null @@ -1,132 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notify from '@ohos.notification' -import image from '@ohos.multimedia.image' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' -var imageBuffer -var opts -var pubimage -describe('ActsAnsPublishImageTest', function () { - console.info("===========ActsDoNotSubscriberTest start====================>"); - - //consume - function consumeCallbackOne(err,data) { - console.debug("==========================>consumeDoNotCallback1 data : =======================>" +err+ JSON.stringify(data)); - checkConsumeData(data) - } - function consumeCallbackTwo(err,data) { - console.debug("==========================>consumeDoNotCallback2 data : =======================>" +err+ JSON.stringify(data)); - checkConsumeData(data) - } - function checkConsumeData(data){ - expect(typeof(data)).assertEqual("object"); - expect(data.id).assertEqual(1); - expect(data.content.contentType).assertEqual(notify.ContentType.NOTIFICATION_CONTENT_PICTURE); - expect(data.content.picture.title).assertEqual("image_title"); - expect(data.content.picture.text).assertEqual("image_text"); - expect(data.content.picture.additionalText).assertEqual("image_additionalText"); - expect(data.content.picture.briefText).assertEqual("image_briefText"); - expect(data.content.picture.expandedTitle).assertEqual("expandedTitle"); -// expect(typeof(data.content.picture.picture)).assertEqual(); - expect(data.slotType).assertEqual(notify.SlotType.SOCIAL_COMMUNICATION); - expect(data.classification).assertEqual("classification1"); - expect(data.sortingKey).assertEqual("sortingKey1"); - } - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeDoNotOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeDoNotCallback=======================>"); - } - function publishCallback001(){ - console.log('ActsAnsPublishImageTest ACTS_Publish_0100 asyncCallback') - } - /* - * @tc.number: ActsDoNotSubscriber_test_0100 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsPublishImage_test_0100', 0, async function (done) { - console.debug("===============ActsDoNotSubscriber_test_0100======begin====================>"); - - var subInfo ={ - onConsume:consumeCallbackOne, - onConnecte:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, subscribeCallback); - } - catch(err) { - console.error('=ActsDoNotSubscriber_test_0100 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0100=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0200 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0200', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0200======begin====================>"); - var subInfo ={ - onConsume:consumeCallbackTwo, - onConnecte:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - await notify.subscribe(subInfo,subscribeCallback); - }catch(err) { - console.error('=ActsDoNotSubscriber_test_0200 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0200=======end3===================>"); - done(); - }) - /* - * @tc.number: ACTS_publishTest_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish - */ - it('ACTS_publishTest_0100', 0,async function (done) { - imageBuffer = new ArrayBuffer(32); - opts = {alphaType: 0, editable: true, pixelFormat: 4, scaleMode: 1, size: {height: 2, width: 3}} - const promise_Large = image.createPixelMap(pubimage, opts); - promise_Large.then((data) => { - console.debug("==========================createPixelMap_promise_Large=======================>"); - pubimage = data; - console.debug("==========================createPixelMap_promise_Large largeIcon=======================>"+pubimage); - }) - await notify.publish({ - id: 1, - content: { - contentType: notify.ContentType.NOTIFICATION_CONTENT_PICTURE, - picture: { - title: "image_title", - text: "image_text", - additionalText: "image_additionalText", - briefText:"image_brief", - expandedTitle:"expandedTitle", - picture:pubimage - }, - }, - slotType:notify.SlotType.SOCIAL_COMMUNICATION, - classification:"classification1", - sortingKey:"sortingKey1", - },publishCallback001); - }) -}) - diff --git a/notification/ans_standard/publish_test/publishimage/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/publishimage/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/publishimage/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/subscribe/BUILD.gn b/notification/ans_standard/publish_test/subscribe/BUILD.gn deleted file mode 100644 index a2b04dc63be55da8145a4f9c33205b8f037d333c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/BUILD.gn +++ /dev/null @@ -1,25 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -group("subscribe") { - testonly = true - if (is_standard_system) { - deps = [ - "publishfirst:ActsAnsPublishOneTest", - "publishsecond:ActsAnsPublishTwoTest", - "subscribe:ActsAnsSubscriberTest", - ] - } -} diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/BUILD.gn b/notification/ans_standard/publish_test/subscribe/publishfirst/BUILD.gn deleted file mode 100644 index 9f205f33395723b30d707a5c54c49d74080fb87c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsPublishOneTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsPublishOneTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/Test.json b/notification/ans_standard/publish_test/subscribe/publishfirst/Test.json deleted file mode 100644 index 6213151aebbe1f221a10e64c8f91a4a01367ca0b..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsanspublishonetest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsPublishOneTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/config.json b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/config.json deleted file mode 100644 index 87172985b138bf2c3fcfb40c8866fbf857d4ccd6..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsanspublishonetest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsanspublishonetest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsanspublishonetest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index fc2437b2b0af5bd75dfc14e0ea743d011159ede3..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 发布接口调用 - -
diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 1e896cb97197887cb4e2ffe9fa7acf74be61160f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "publish" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index 2907d31f53f87061a1a9d4d59ad367e6d261a0d3..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsPublishOneTest', function () { - function publishCallback001(){ - console.log('ActsAnsPublishTest ACTS_PublishTest_0100 asyncCallback') - } - - /* - * @tc.number: ACTS_PublishTest_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish - */ - it('ACTS_PublishTest_0100', 0,async function (done) { - await notification.publish({ - id: 1, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test1_title", - text: "test1_text", - additionalText: "test1_additionalText" - }, - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION, - classification:"classification1", - sortingKey:"sortingKey1", - },publishCallback001); - done(); - }) -}) \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishfirst/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishfirst/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/subscribe/publishfirst/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/subscribe/publishfirst/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/BUILD.gn b/notification/ans_standard/publish_test/subscribe/publishsecond/BUILD.gn deleted file mode 100644 index 3136d32fdbfd033a9efed67a68b70d61245122ea..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsPublishTwoTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsPublishTwoTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/Test.json b/notification/ans_standard/publish_test/subscribe/publishsecond/Test.json deleted file mode 100644 index 21c1c5f185906eb6699c551e4786bc8f5061f629..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsanspublishtwotest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsPublishTwoTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/config.json b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/config.json deleted file mode 100644 index cfa8a91f0e7874c6f4fb028027206c86f1b35729..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsanspublishtwotest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsanspublishtwotest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsanspublishtwotest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index b235e58c10080925fdcea67bc3da34a5cb097f9b..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 第二个发布接口 - -
diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 2af91e1045f5460ee1cae9c38ef54f7cc158a4a0..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "publish2" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/test/ExampleJsunit.test.js b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/test/ExampleJsunit.test.js deleted file mode 100644 index c2be5ce06737ea7c5c2d902be01f8a2a704c8a0c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/test/ExampleJsunit.test.js +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import notification from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsPublishTwoTest', function () { - function publishCallback002(){ - console.log('ActsAnsPublishTest ACTS_PublishTest_0200 asyncCallback') - } - - /* - * @tc.number: ACTS_PublishTwoTest_0200 - * @tc.name: publish() - * @tc.desc: verify the function of publish - */ - it('ACTS_PublishTwoTest_0200', 0,async function (done) { - await notification.publish({ - id: 2, - content: { - contentType: notification.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test2_title", - text: "test2_text", - additionalText: "test2_additionalText" - }, - }, - slotType:notification.SlotType.SOCIAL_COMMUNICATION, - classification:"classification2", - sortingKey:"sortingKey2", - },publishCallback002); - done(); - }) -}) \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/test/List.test.js deleted file mode 100644 index c0b876e81cf0a75db974ee932d8fc06a1d5a6e66..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/publishsecond/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./ExampleJsunit.test.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/publishsecond/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/subscribe/publishsecond/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/subscribe/publishsecond/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/BUILD.gn b/notification/ans_standard/publish_test/subscribe/subscribe/BUILD.gn deleted file mode 100644 index 47ae08aed320cd07fa5d97564dfa1e851a7ed091..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsSubscriberTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsSubscriberTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/Test.json b/notification/ans_standard/publish_test/subscribe/subscribe/Test.json deleted file mode 100644 index 526130c0530938dbd1ccda4ebd02e2b89cf59d51..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsanssubscribertest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsSubscriberTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/config.json b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/config.json deleted file mode 100644 index b1343a9f3451353f85e8a72532bcee8d7814de70..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsanssubscribertest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsanssubscribertest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsanssubscribertest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index e42bdfdd29c1e18681d7f2924d1b98191d47fa4a..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 订阅发布 - -
diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 30895093f1f793272b0638cbde300dd08dfcf1c0..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "Subscriber" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/test/List.test.js deleted file mode 100644 index 41999288d49304127387014dc88894130a148ab4..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./Subscriber.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/test/Subscriber.js b/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/test/Subscriber.js deleted file mode 100644 index 5c4d6a511b9e718de8cc2062adfa6d280cac8c1a..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/subscribe/subscribe/entry/src/main/js/test/Subscriber.js +++ /dev/null @@ -1,358 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notify from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsSubscriberTest', function () { - console.info("===========ActsDoNotSubscriberTest start====================>"); - - //consume - function consumeCallbackOne(err,data) { - console.debug("==========================>consumeDoNotCallback1 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackTwo(err,data) { - console.debug("==========================>consumeDoNotCallback2 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackTree(err,data) { - console.debug("==========================>consumeDoNotCallback3 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackFour(err,data) { - console.debug("==========================>consumeDoNotCallback4 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackFive(err,data) { - console.debug("==========================>consumeDoNotCallback5 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackSix(err,data) { - console.debug("==========================>consumeDoNotCallback6 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackSeven(err,data) { - console.debug("==========================>consumeDoNotCallback7 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackEight(err,data) { - console.debug("==========================>consumeDoNotCallback8 data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbacka(err,data) { - console.debug("==========================>consumeCallbacka data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackb(err,data) { - console.debug("==========================>consumeCallbackb data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackc(err,data) { - console.debug("==========================>consumeCallbackc data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackd(err,data) { - console.debug("==========================>consumeCallbackd data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbacke(err,data) { - console.debug("==========================>consumeCallbacke data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - function consumeCallbackf(err,data) { - console.debug("==========================>consumeCallbackf data : =======================>" +err+ JSON.stringify(data)); - expect(typeof(data)).assertEqual("object") - } - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeDoNotOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeDoNotCallback=======================>"); - - } - function publishCallback001(){ - console.log('ActsAnsSubscriberTest ACTS_Publish_0100 asyncCallback') - } - /* - * @tc.number: ActsDoNotSubscriber_test_0100 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0100', 0, async function (done) { - console.debug("===============ActsDoNotSubscriber_test_0100======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackOne, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, subscribeCallback); - } - catch(err) { - console.error('=ActsDoNotSubscriber_test_0100 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0100=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0200 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0200', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0200======begin====================>"); - var subInfo ={ - onConsumed:consumeCallbackTwo, - onConnected:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - await notify.subscribe(subInfo,subscribeCallback); - }catch(err) { - console.error('=ActsDoNotSubscriber_test_0200 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0200=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0300 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0300', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0300======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackTree, - onConnected:subscribeOnCallback, - } - var subInfo2 ={ - onConsumed:consumeCallbackFour, - onConnected:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - await notify.subscribe(subInfo2,subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0300 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0300=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0400 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0400', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0400======begin====================>"); - try{ - await notify.subscribe({ - onConsumed:consumeCallbackFive, - onConnected:subscribeOnCallback, - },subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0400 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0400=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0500 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0500', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0500======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackSix, - onConnected:subscribeOnCallback, - } - var subInfo2 ={ - onConsumed:consumeCallbackSeven, - onConnected:subscribeOnCallback, - } - try{ - await notify.subscribe(subInfo,subscribeCallback); - await notify.subscribe(subInfo,subscribeCallback); - await notify.subscribe(subInfo2,subscribeCallback); - await notify.subscribe({ - onConsumed:consumeCallbackEight, - onConnected:subscribeOnCallback, - },subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0500 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0500=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0600 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0600', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0600======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbacka, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, {bundleNames:["com.neu.actsanspublishonetest"]},subscribeCallback); - } - catch(err) { - console.error('=ActsSubscriber_test_0600 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0600=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0700 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0700', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0700======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackb, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, {bundleNames:["com.neu.actsanspublishonetest"]}).then( - console.log("ActsSubscriber_test_0700=======promise") - ); - } - catch(err) { - console.error('=ActsSubscriber_test_0700 订阅 promise err:'+err); - } - console.debug("===============ActsSubscriber_test_0700=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0800 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0800', 0, async function (done) { - console.debug("===============ActsDoNotSubscriber_test_0100======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackc, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, {bundleNames:["com.neu.actsanspublishonetest","com.neu.actsanspublishtwotest"]},subscribeCallback); - } - catch(err) { - console.error('=ActsSubscriber_test_0800 订阅 subscribeCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0800=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0900 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0900', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0800======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackd, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, {bundleNames:["com.neu.actsanspublishonetest","com.neu.actsanspublishtwotest"],}).then( - console.log("ActsSubscriber_test_0900=======promise") - ); - } - catch(err) { - console.error('=ActsSubscriber_test_0900 订阅 promise err:'+err); - } - console.debug("===============ActsSubscriber_test_0900=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_1000 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_1000', 0, async function (done) { - console.debug("===============ActsSubscriber_test_1000======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbacke, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, {bundleNames:["com.neu.actsanspublishonetest","com.neu.actsanspublishonetest"]},subscribeCallback); - } - catch(err) { - console.error('=ActsSubscriber_test_1000 订阅 subscribeCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_1000=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_1100 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_1100', 0, async function (done) { - console.debug("===============ActsSubscriber_test_1100======begin====================>"); - - var subInfo ={ - onConsumed:consumeCallbackf, - onConnected:subscribeOnCallback, - } - try { - await notify.subscribe(subInfo, {bundleNames:["com.neu.actsanspublishonetest","com.neu.actsanspublishonetest"]}).then( - console.log("ActsSubscriber_test_1100=======promise") - ); - } - catch(err) { - console.error('=ActsSubscriber_test_1100 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_1100=======end3===================>"); - done(); - }) - /* - * @tc.number: ACTS_publishTest_0100 - * @tc.name: publish() - * @tc.desc: verify the function of publish - */ - it('ACTS_publishTest_0100', 0,async function (done) { - await notify.publish({ - id: 1, - content: { - contentType: notify.ContentType.NOTIFICATION_CONTENT_BASIC_TEXT, - normal: { - title: "test1_title", - text: "test1_text", - additionalText: "test1_additionalText" - }, - }, - slotType:notify.SlotType.SOCIAL_COMMUNICATION, - classification:"classification1", - sortingKey:"sortingKey1", - },publishCallback001); - }) -}) - diff --git a/notification/ans_standard/publish_test/subscribe/subscribe/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/subscribe/subscribe/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/subscribe/subscribe/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/unsubscribe/BUILD.gn b/notification/ans_standard/publish_test/unsubscribe/BUILD.gn deleted file mode 100644 index 8c499e5be37ad7ecee772330bffde1b22e5630d7..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/BUILD.gn +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//test/xts/tools/build/suite.gni") - -ohos_js_hap_suite("ActsAnsUnSubscriberTest") { - hap_profile = "./entry/src/main/config.json" - deps = [ - ":hjs_demo_js_assets", - ":hjs_demo_resources", - ] - certificate_profile = "./signature/openharmony_sx.p7b" - hap_name = "ActsAnsUnSubscriberTest" -} -ohos_js_assets("hjs_demo_js_assets") { - source_dir = "./entry/src/main/js/default" -} -ohos_resources("hjs_demo_resources") { - sources = [ "./entry/src/main/js/resources" ] - hap_profile = "./entry/src/main/config.json" -} diff --git a/notification/ans_standard/publish_test/unsubscribe/Test.json b/notification/ans_standard/publish_test/unsubscribe/Test.json deleted file mode 100644 index 8d273a47c632a66edd4a0c145637fb73eb0cc38b..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/Test.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "description": "Configuration for hjunit demo Tests", - "driver": { - "type": "JSUnitTest", - "test-timeout": "300000", - "package": "com.example.actsansunsubscribertest", - "shell-timeout": "60000" - }, - "kits": [ - { - "test-file-name": [ - "ActsAnsUnSubscriberTest.hap" - ], - "type": "AppInstallKit", - "cleanup-apps": true - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/config.json b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/config.json deleted file mode 100644 index 0e966bd42b046c1e32c4cb558d83863534cef842..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/config.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "app": { - "bundleName": "com.neu.actsansunsubscribertest", - "vendor": "example", - "version": { - "code": 1, - "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" - } - }, - "deviceConfig": {}, - "module": { - "package": "com.example.actsansunsubscribertest", - "name": ".MyApplication", - "deviceType": [ - "phone" - ], - "distro": { - "deliveryWithInstall": true, - "moduleName": "entry", - "moduleType": "entry" - }, - "abilities": [ - { - "skills": [ - { - "entities": [ - "entity.system.home" - ], - "actions": [ - "action.system.home" - ] - } - ], - "name": "com.example.actsansunsubscribertest.MainAbility", - "icon": "$media:icon", - "description": "$string:mainability_description", - "label": "$string:app_name", - "type": "page", - "isVisible": "true", - "launchType": "standard", - "visible": true - } - ], - "js": [ - { - "pages": [ - "pages/index/index" - ], - "name": "default", - "window": { - "designWidth": 720, - "autoDesignWidth": false - } - } - ] - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/app.js b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/app.js deleted file mode 100644 index 2a68c1992145a976957d7dcdd69a7e9c2e8e9877..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/app.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -export default { - onCreate() { - console.info('AceApplication onCreate'); - }, - onDestroy() { - console.info('AceApplication onDestroy'); - } -}; diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/i18n/en-US.json b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/i18n/en-US.json deleted file mode 100644 index e63c70d978a3a53be988388c87182f81785e170c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/i18n/en-US.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "Hello", - "world": "World" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/i18n/zh-CN.json b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/i18n/zh-CN.json deleted file mode 100644 index de6ee5748322f44942c1b003319d8e66c837675f..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/i18n/zh-CN.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "strings": { - "hello": "您好", - "world": "世界" - } -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.css b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.css deleted file mode 100644 index 6fda792753f2e15f22b529c7b90a82185b2770bf..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.css +++ /dev/null @@ -1,9 +0,0 @@ -.container { - flex-direction: column; - justify-content: center; - align-items: center; -} - -.title { - font-size: 100px; -} diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.hml b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.hml deleted file mode 100644 index 778bf5f51bb09c729b47edf6d1695b65d1efd188..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.hml +++ /dev/null @@ -1,5 +0,0 @@ -
- - 取消订阅 - -
diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.js b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.js deleted file mode 100644 index c3b6a96287aa8ad4c9bf0e44ccba5d69b68ae02c..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/default/pages/index/index.js +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import file from '@system.file' -import {Core, ExpectExtend} from 'deccjsunit/index' - -const injectRef = Object.getPrototypeOf(global) || global -injectRef.regeneratorRuntime = require('@babel/runtime/regenerator') - -export default { - data: { - title: "" - }, - onInit() { - this.title = this.$t('strings.world'); - }, - onShow() { - console.info('onShow finish') - const core = Core.getInstance() - const expectExtend = new ExpectExtend({ - 'id': 'extend' - }) - core.addService('expect', expectExtend) - core.init() - - const configService = core.getDefaultService('config') - configService.setConfig(this) - - require('../../../test/List.test') - core.execute() - }, - onReady() { - console.info('onReady'); - }, -} diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/resources/base/element/string.json b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/resources/base/element/string.json deleted file mode 100644 index 30895093f1f793272b0638cbde300dd08dfcf1c0..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/resources/base/element/string.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "string": [ - { - "name": "app_name", - "value": "Subscriber" - }, - { - "name": "mainability_description", - "value": "JS_Phone_Empty Feature Ability" - } - ] -} \ No newline at end of file diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/resources/base/media/icon.png b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/resources/base/media/icon.png deleted file mode 100644 index ce307a8827bd75456441ceb57d530e4c8d45d36c..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/resources/base/media/icon.png and /dev/null differ diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/test/List.test.js b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/test/List.test.js deleted file mode 100644 index 41999288d49304127387014dc88894130a148ab4..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/test/List.test.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -require('./Subscriber.js') \ No newline at end of file diff --git a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/test/Subscriber.js b/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/test/Subscriber.js deleted file mode 100644 index be1c250976cc0d5c7a9a3896ec94585410e65486..0000000000000000000000000000000000000000 --- a/notification/ans_standard/publish_test/unsubscribe/entry/src/main/js/test/Subscriber.js +++ /dev/null @@ -1,298 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import notify from '@ohos.notification' -import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index' - -describe('ActsAnsUnSubscriberTest', function () { - console.info("===========ActsDoNotSubscriberTest start====================>"); - //subscribeOn - function subscribeOnCallback(err) { - console.debug("==========================>subscribeDoNotOnCallback=======================>"); - } - //subscribe - function subscribeCallback(err) { - console.debug("==========================>subscribeDoNotCallback=======================>"); - - } - function unSubscribeCallbackOne(err) { - console.debug("==========================>unSubscribeCallbackOne=======================>"); - } - function unSubscribeCallbackTwo(err) { - console.debug("==========================>unSubscribeCallbackTwo=======================>"); - } - function unSubscribeCallbackThree(err) { - console.debug("==========================>unSubscribeCallbackThree=======================>"); - } - function unSubscribeCallbackFour(err) { - console.debug("==========================>unSubscribeCallbackFour=======================>"); - } - function unSubscribeCallbackFive(err) { - console.debug("==========================>unSubscribeCallbackFive=======================>"); - } - function unSubscribeCallbackSix(err) { - console.debug("==========================>unSubscribeCallbackSix=======================>"); - } - function unSubscribeCallbackSeven(err) { - console.debug("==========================>unSubscribeCallbackSeven=======================>"); - } - function unSubscribeCallbackEight(err) { - console.debug("==========================>unSubscribeCallbackEight=======================>"); - } - - function publishCallback001(){ - console.log('ActsAnsSubscriberTest ACTS_Publish_0100 asyncCallback') - } - - /* - * @tc.number: ActsDoNotSubscriber_test_0100 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0100', 0, async function (done) { - console.debug("===============ActsDoNotSubscriber_test_0100======begin====================>"); - - var subInfoOne ={ -// onConsumed:consumeCallbackOne, - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackOne - } - try { - await notify.subscribe(subInfoOne, subscribeCallback); - } - catch(err) { - console.error('=ActsDoNotSubscriber_test_0100 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe(subInfoOne, unSubscribeCallbackOne); - } - catch(err) { - console.error('=ActsSubscriber_test_0100 取消订阅 unSubscribeCallbackOne err:'+err); - } - console.debug("===============ActsSubscriber_test_0100=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsDoNotSubscriber_test_0200 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0200', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0200======begin====================>"); - - var subInfoOne ={ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackOne - } - try { - await notify.subscribe(subInfoOne, subscribeCallback); - } - catch(err) { - console.error('=ActsSubscriber_test_0200 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe(subInfoOne).then(()=> - console.log("============promise============") - ) - } - catch(err) { - console.error('=ActsSubscriber_test_0200 取消订阅 unSubscribeCallbackOne err:'+err); - } - console.debug("===============ActsSubscriber_test_0200=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0300 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0300', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0300======begin====================>"); - var subInfoTwo ={ - // onConsumed:consumeCallbackTwo, - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackTwo - } - try{ - await notify.subscribe(subInfoTwo,subscribeCallback); - await notify.subscribe(subInfoTwo,subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0300 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe(subInfoTwo, unSubscribeCallbackTwo); - await notify.unsubscribe(subInfoTwo, unSubscribeCallbackTwo); - } - catch(err) { - console.error('=ActsSubscriber_test_0300 取消订阅 unSubscribeCallbackOne err:'+err); - } - console.debug("===============ActsSubscriber_test_0300=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0400 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0400', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0400======begin====================>"); - var subInfoTwo ={ - // onConsumed:consumeCallbackTwo, - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackTwo - } - try{ - await notify.subscribe(subInfoTwo,subscribeCallback); - await notify.subscribe(subInfoTwo,subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0400 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe(subInfoTwo).then( - console.log("=======unsubscribeTwo Promise=======") - ) - await notify.unsubscribe(subInfoTwo).then( - console.log("=======unsubscribeTwo Promise=======") - ) - } - catch(err) { - console.error('=ActsSubscriber_test_0400 取消订阅 unSubscribeCallbackOne err:'+err); - } - console.debug("===============ActsSubscriber_test_0400=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0500 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0500', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0500======begin====================>"); - - var subInfo1 ={ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackThree, - } - var subInfo2 ={ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackFour, - } - try{ - await notify.subscribe(subInfo1,subscribeCallback); - await notify.subscribe(subInfo2,subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0500 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe(subInfo1, unSubscribeCallbackThree); - await notify.unsubscribe(subInfo2, unSubscribeCallbackFour); - } - catch(err) { - console.error('=ActsSubscriber_test_0500 取消订阅 unSubscribeCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0500=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0600 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0600', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0600======begin====================>"); - - var subInfo1 ={ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackThree, - } - var subInfo2 ={ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackFour, - } - try{ - await notify.subscribe(subInfo1,subscribeCallback); - await notify.subscribe(subInfo2,subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0600 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe(subInfo1).then( - console.log("=======unsubscribeTree Promise=======") - ) - await notify.unsubscribe(subInfo2).then( - console.log("=======unsubscribeTree Promise=======") - ) - } - catch(err) { - console.error('=ActsSubscriber_test_0600 取消订阅 unSubscribeCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0600=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0700 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0700', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0700======begin====================>"); - try{ - await notify.subscribe({ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackFive - },subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0700 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe({ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackFive - },unSubscribeCallbackFive); - }catch(err) { - console.error('=ActsSubscriber_test_0700 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0700=======end3===================>"); - done(); - }) - /* - * @tc.number: ActsSubscriber_test_0800 - * @tc.name: subscribe() - * @tc.desc: verify the function of subscribe - */ - it('ActsSubscriber_test_0800', 0, async function (done) { - console.debug("===============ActsSubscriber_test_0800======begin====================>"); - try{ - await notify.subscribe({ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackFive - },subscribeCallback); - }catch(err) { - console.error('=ActsSubscriber_test_0800 订阅 subscribeDoNotCallback err:'+err); - } - try{ - await notify.unsubscribe({ - onConnected:subscribeOnCallback, - onDisConnect:unSubscribeCallbackFive - }).then( - console.log("=======unsubscribeFour Promise=======") - ) - }catch(err) { - console.error('=ActsSubscriber_test_0800 订阅 subscribeDoNotCallback err:'+err); - } - console.debug("===============ActsSubscriber_test_0800=======end3===================>"); - done(); - }) -}) - diff --git a/notification/ans_standard/publish_test/unsubscribe/signature/openharmony_sx.p7b b/notification/ans_standard/publish_test/unsubscribe/signature/openharmony_sx.p7b deleted file mode 100644 index 9be1e98fa4c0c28ca997ed660112fa16b194f0f5..0000000000000000000000000000000000000000 Binary files a/notification/ans_standard/publish_test/unsubscribe/signature/openharmony_sx.p7b and /dev/null differ diff --git a/notification/ans_standard/publish_test/wantagent/sub/Test.json b/notification/ans_standard/publish_test/wantagent/sub/Test.json index ff7ba7389c0ca0c8cd55ff07a43a52c3e4972f71..e39dec52aa8aac4e987925eb97604950fdac4da1 100644 --- a/notification/ans_standard/publish_test/wantagent/sub/Test.json +++ b/notification/ans_standard/publish_test/wantagent/sub/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsansactivesubscribertest", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/wantagent/sub/entry/package.json b/notification/ans_standard/publish_test/wantagent/sub/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/sub/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/test1/Test.json b/notification/ans_standard/publish_test/wantagent/test1/Test.json index f411d983178accfe5de00eeb2f4d625e0584fcd4..b983a5cba90a1b4cb0e82619c1e5f35ed17cdf7e 100644 --- a/notification/ans_standard/publish_test/wantagent/test1/Test.json +++ b/notification/ans_standard/publish_test/wantagent/test1/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.WantAgentTest1", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/wantagent/test1/entry/package.json b/notification/ans_standard/publish_test/wantagent/test1/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/test1/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/test2/Test.json b/notification/ans_standard/publish_test/wantagent/test2/Test.json index 742907522d3c5e6378065a9786f302c906d733f2..bd61ec37f554df3c6e5c9dcf7c91172306d6c1d9 100644 --- a/notification/ans_standard/publish_test/wantagent/test2/Test.json +++ b/notification/ans_standard/publish_test/wantagent/test2/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.WantAgenTest2", "shell-timeout": "60000" }, diff --git a/notification/ans_standard/publish_test/wantagent/test2/entry/package.json b/notification/ans_standard/publish_test/wantagent/test2/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/test2/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent1/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent1/Test.json index ea78e3771ce2b708872409568c3bf85457d30d16..cc514ef881f2f2eeda74c9a4fc1d262ad0948e66 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent1/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent1/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagentonetest", "shell-timeout": "60000" }, @@ -10,9 +10,10 @@ { "test-file-name": [ "ActsAnsWantAgentOneTest.hap" + "test1.hap" ], "type": "AppInstallKit", "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent1/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent1/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent1/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent1/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent1/entry/src/main/js/test/WantAgent.test.js index f26b451230fcb43a38c1c4d6ac7effec8c1a6cf1..85195a960a95b334f716372318aef862ca24c815 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent1/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent1/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentOneTest', function () { console.info('----ActsWantAgentTest----'); @@ -82,6 +82,9 @@ describe('ActsAnsWantAgentOneTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0100====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent1promise/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent1promise/Test.json index 2b6ddf4eaf223dc340594471ccbfbfa5bb695b6c..1e4ac5bc225e312732fbd901a32b88a15df4fffa 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent1promise/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent1promise/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagentoneprotest", "shell-timeout": "60000" }, @@ -10,9 +10,10 @@ { "test-file-name": [ "ActsAnsWantAgentOneProTest.hap" + "test1" ], "type": "AppInstallKit", "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/src/main/js/test/WantAgent.test.js index f433b79dbbd05e9b1c5ee86b0477f843846e0f60..16a94c397721c0f4776654fa9ab4abfbee9fe75e 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent1promise/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentOneProTest', function () { console.info('----ActsWantAgentTest----'); @@ -53,7 +53,7 @@ describe('ActsAnsWantAgentOneProTest', function () { wantAgentFlags:[Flags.UPDATE_PRESENT_FLAG] } console.info('----getWantAgent before----'); - await wantAgent.getWantAgent(agentInfo).then( + wantAgent.getWantAgent(agentInfo).then( (data) => { WantAgent = data; console.info('----getWantAgent success!----'); @@ -74,7 +74,10 @@ describe('ActsAnsWantAgentOneProTest', function () { done(); } ); - done(); + done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0200====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent2/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent2/Test.json index 9c89e4daf17cd969bb884be47b6b7c547d8de2e1..63e821202937e9f3da19738100f7e8dc3b4868dd 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent2/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent2/Test.json @@ -2,17 +2,19 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagenttwotest", "shell-timeout": "60000" }, "kits": [ { "test-file-name": [ - "ActsAnsWantAgentTwoTest.hap" + "ActsAnsWantAgentTwoTest.hap", + "test1.hap", + "test2.hap" ], "type": "AppInstallKit", "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent2/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent2/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent2/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent2/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent2/entry/src/main/js/test/WantAgent.test.js index b719034ed343aaaea6505c43f85628ac7e8b4b1b..f1911b550e02af2dd16bab1c5a800e18de443eed 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent2/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent2/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentTwoTest', function () { /* @@ -99,6 +99,9 @@ describe('ActsAnsWantAgentTwoTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0300====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent2promise/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent2promise/Test.json index 5e28981a9f67833831bdba52c8e231d300575b4b..96ddb586b771582443584b1f78bad6fb8977a326 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent2promise/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent2promise/Test.json @@ -2,17 +2,19 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagenttwoprotest", "shell-timeout": "60000" }, "kits": [ { "test-file-name": [ - "ActsAnsWantAgentTwoProTest.hap" + "ActsAnsWantAgentTwoProTest.hap", + "test1.hap", + "test2.hap" ], "type": "AppInstallKit", "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/src/main/js/test/WantAgent.test.js index 06ffa081b769b7befe5ceda209722f7a5736f7d2..c81b1e43b3a0e4972d8d13eeae0eae3c9c64b02f 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent2promise/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentTwoProTest', function () { /* @@ -93,6 +93,9 @@ describe('ActsAnsWantAgentTwoProTest', function () { } ); done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0400====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent3/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent3/Test.json index 4a88a624c5bcba7b4c846590d4d2f35647fd32b2..3d14ed205b61ee7b763f1e83458032f1b7f04a96 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent3/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent3/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagenttreetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent3/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent3/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent3/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent3/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent3/entry/src/main/js/test/WantAgent.test.js index d63e4efb29077fd829b9dfb06996681b52da127c..61c096a6c80ede9397702c8f57693c8aea1292d5 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent3/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent3/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentTreeTest', function () { /* @@ -80,6 +80,9 @@ describe('ActsAnsWantAgentTreeTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0500====>"); + }, time) } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent3promise/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent3promise/Test.json index bfaa51784ac99cf31873ef94f56b8d02787b210c..2560ec6f854e7a7cc210eb1befcd5eb783131cb3 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent3promise/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent3promise/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagenttreeprotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/src/main/js/test/WantAgent.test.js index 38a65c4b3ed0a35c0b362d9c088909d9ff1620ae..1895e439df22ab4b1a86fbb81873da694f2637d9 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent3promise/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentTreeProTest', function () { /* @@ -74,6 +74,9 @@ describe('ActsAnsWantAgentTreeProTest', function () { } ); done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0600====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent4/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent4/Test.json index e2769898738cdf9063aed9b72866fca76531df72..20fd9ad2c9b374fa4dcb7f9e96734cf62392130c 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent4/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent4/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagentfourtest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent4/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent4/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent4/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent4/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent4/entry/src/main/js/test/WantAgent.test.js index cd98672df78597aaae549c84c12dbaa82e21353b..eb19a1fbd1a61ef458af6ca15e211bd9059f8853 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent4/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent4/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentFourTest', function () { /* @@ -80,6 +80,9 @@ describe('ActsAnsWantAgentFourTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0700====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent4promise/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent4promise/Test.json index 39921808905c4121f0ca488e038fa6654dbd72ae..7c3583f3feb734c5c069a220fff20cabc6d86ef5 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent4promise/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent4promise/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagentfourprotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/src/main/js/test/WantAgent.test.js index f9299b36213ab29df390f38a0e0358fbb61c2e1f..a6348780221d537c05b8d89446bfc5ae1ff2b80b 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent4promise/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentFourProTest', function () { /* @@ -74,6 +74,9 @@ describe('ActsAnsWantAgentFourProTest', function () { } ); done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0800====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent5/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent5/Test.json index 8aa1e9170fa84bbb8c4d7605ecf1dc2f5ac017e6..c8b6ec6d3058f1ddc095ff2bb82e47e274a593b6 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent5/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent5/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagentfivetest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent5/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent5/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent5/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent5/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent5/entry/src/main/js/test/WantAgent.test.js index d02390b5317e42a875eff44c380d0a994db23a84..5341f2ae17797ec72c40d0dbf60e57f8ed20ef90 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent5/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent5/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentFiveTest', function () { /* @@ -80,6 +80,9 @@ describe('ActsAnsWantAgentFiveTest', function () { expect(typeof(data)).assertEqual("object"); } done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_0900====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publish_test/wantagent/wantagent5promise/Test.json b/notification/ans_standard/publish_test/wantagent/wantagent5promise/Test.json index 02362caad6005de9c69e94eb4284d3c78801f512..341f5578aa66708added3a874766c2336eeb9c82 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent5promise/Test.json +++ b/notification/ans_standard/publish_test/wantagent/wantagent5promise/Test.json @@ -2,7 +2,7 @@ "description": "Configuration for hjunit demo Tests", "driver": { "type": "JSUnitTest", - "test-timeout": "300000", + "test-timeout": "60000", "package": "com.example.actsanswantagentfiveprotest", "shell-timeout": "60000" }, @@ -15,4 +15,4 @@ "cleanup-apps": true } ] -} \ No newline at end of file +} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/package.json b/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/src/main/js/test/WantAgent.test.js b/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/src/main/js/test/WantAgent.test.js index f9785fde3e20684bb0dfda6ea2ab9caf3cbc35a5..5eec00e0ebaf9fea9da2fa6e8c696d619616e893 100644 --- a/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/src/main/js/test/WantAgent.test.js +++ b/notification/ans_standard/publish_test/wantagent/wantagent5promise/entry/src/main/js/test/WantAgent.test.js @@ -16,7 +16,7 @@ import wantAgent from '@ohos.wantAgent'; import { OperationType, Flags } from '@ohos.wantagent'; import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'; - +var time = 1000 var WantAgent; describe('ActsAnsWantAgentFiveProTest', function () { /* @@ -74,6 +74,9 @@ describe('ActsAnsWantAgentFiveProTest', function () { } ); done(); + setTimeout(function(){ + console.debug("====>time out ACTS_SetWant_1000====>"); + }, time); } ); console.info('----getWantAgent after----'); diff --git a/notification/ans_standard/publishicontest/entry/package.json b/notification/ans_standard/publishicontest/entry/package.json new file mode 100644 index 0000000000000000000000000000000000000000..69a88e3b65423624fe7ea8b0f8beefcc62cc3d5f --- /dev/null +++ b/notification/ans_standard/publishicontest/entry/package.json @@ -0,0 +1 @@ +{} diff --git a/notification/ans_standard/publishicontest/hap/ActsAnsIconTest.hap b/notification/ans_standard/publishicontest/hap/ActsAnsIconTest.hap new file mode 100755 index 0000000000000000000000000000000000000000..acd006561e5f6fc747caa6283b18d43fea191bcd Binary files /dev/null and b/notification/ans_standard/publishicontest/hap/ActsAnsIconTest.hap differ