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

!3613 适配OH API8 JS接口返回值不一致问题

Merge pull request !3613 from shilei91/OpenHarmony-3.1-Release
......@@ -158,7 +158,7 @@ describe('ActsBmsQueryAbilityByWant', function () {
expect(data.permissions.length).assertEqual(0);
expect(data.deviceCapabilities.length).assertEqual(0);
expect(data.deviceTypes[0]).assertEqual('phone');
expect(data.process).assertEqual('');
expect(data.process).assertEqual(SYSTEM_NAME);
expect(data.uri).assertEqual('');
expect(data.bundleName).assertEqual(SYSTEM_NAME);
expect(data.moduleName).assertEqual("entry");
......
......@@ -54,7 +54,7 @@ describe('ActsBmsJsTest', function () {
expect(abilityInfo1.isVisible).assertEqual(true);
expect(abilityInfo1.permissions.length).assertEqual(0);
expect(abilityInfo1.deviceTypes[0]).assertEqual('phone');
expect(abilityInfo1.process).assertEqual("");
expect(abilityInfo1.process).assertEqual(BUNDLE_NAME2);
expect(abilityInfo1.uri).assertEqual("");
expect(abilityInfo1.bundleName).assertEqual(BUNDLE_NAME2);
expect(abilityInfo1.moduleName).assertEqual("entry");
......@@ -130,7 +130,7 @@ describe('ActsBmsJsTest', function () {
expect(abilityInfo1.isVisible).assertEqual(true);
expect(abilityInfo1.permissions.length).assertEqual(0);
expect(abilityInfo1.deviceTypes[0]).assertEqual('phone');
expect(abilityInfo1.process).assertEqual("");
expect(abilityInfo1.process).assertEqual(BUNDLE_NAME4);
expect(abilityInfo1.uri).assertEqual("");
expect(abilityInfo1.bundleName).assertEqual(BUNDLE_NAME4);
expect(abilityInfo1.moduleName).assertEqual("entry");
......@@ -173,7 +173,7 @@ describe('ActsBmsJsTest', function () {
expect(abilityInfo1.isVisible).assertEqual(true);
expect(abilityInfo1.permissions.length).assertEqual(0);
expect(abilityInfo1.deviceTypes[0]).assertEqual('phone');
expect(abilityInfo1.process).assertEqual("");
expect(abilityInfo1.process).assertEqual(BUNDLE_NAME5);
expect(abilityInfo1.uri).assertEqual("");
expect(abilityInfo1.bundleName).assertEqual(BUNDLE_NAME5);
expect(abilityInfo1.moduleName).assertEqual("entry");
......@@ -205,7 +205,7 @@ describe('ActsBmsJsTest', function () {
expect(info.isVisible).assertEqual(true);
expect(info.permissions.length).assertEqual(0);
expect(info.deviceTypes[0]).assertEqual('phone');
expect(info.process).assertEqual("");
expect(info.process).assertEqual(BUNDLE_NAME3);
expect(info.uri).assertEqual("");
expect(info.bundleName).assertEqual(BUNDLE_NAME3);
expect(info.moduleName).assertEqual("entry");
......
......@@ -85,6 +85,7 @@
"autoDesignWidth": false
}
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -232,7 +232,7 @@ export default function GetabilityInfo() {
expect(Array.isArray(data.deviceCapabilities)).assertEqual(true);
expect(data.deviceTypes[0]).assertEqual("phone");
expect(typeof (data.process)).assertEqual("string");
expect(data.process).assertEqual("");
expect(data.process).assertEqual("com.open.harmony.packagemag");
expect(typeof (data.uri)).assertEqual("string");
expect(data.uri).assertEqual("");
expect(data.moduleName).assertEqual("entry");
......@@ -251,7 +251,7 @@ export default function GetabilityInfo() {
expect(typeof (info.accessTokenId)).assertEqual("number");
expect(info.accessTokenId > 0).assertTrue();
expect(typeof (info.description)).assertEqual("string");
expect(info.description).assertEqual("$string:mainability_description");
expect(info.description).assertEqual("$string:entry_description");
expect(typeof (info.descriptionId)).assertEqual("number");
expect(info.descriptionId > 0).assertTrue();
expect(typeof (info.icon)).assertEqual("string");
......@@ -268,7 +268,7 @@ export default function GetabilityInfo() {
expect(typeof (info.supportedModes)).assertEqual("number");
expect(info.supportedModes).assertEqual(0);
expect(typeof (info.process)).assertEqual("string");
expect(info.process).assertEqual("");
expect(info.process).assertEqual("com.open.harmony.packagemag");
expect(Array.isArray(info.moduleSourceDirs)).assertEqual(true);
expect(info.moduleSourceDirs[0]).assertEqual("/data/app/el1/bundle/public/com.open.harmony.packagemag/com.open.harmony.packagemag");
expect(Array.isArray(info.permissions)).assertEqual(true);
......@@ -282,7 +282,7 @@ export default function GetabilityInfo() {
expect(data.icon).assertEqual("$media:icon");
expect(data.isVisible).assertEqual(true);
expect(data.deviceTypes[0]).assertEqual("phone");
expect(data.process).assertEqual("");
expect(data.process).assertEqual("com.example.third1");
expect(data.uri).assertEqual("");
expect(data.moduleName).assertEqual("entry");
expect(data.type).assertEqual(1);
......@@ -308,7 +308,7 @@ export default function GetabilityInfo() {
expect(info.name).assertEqual("com.example.third1");
expect(info.codePath).assertEqual("/data/app/el1/bundle/public/com.example.third1");
expect(info.accessTokenId > 0).assertTrue();
expect(info.description).assertEqual("$string:mainability_description");
expect(info.description).assertEqual("$string:entry_description");
expect(info.descriptionId > 0).assertTrue();
expect(info.icon).assertEqual("$media:icon");
expect(info.iconId > 0).assertTrue();
......@@ -317,7 +317,7 @@ export default function GetabilityInfo() {
expect(info.systemApp).assertEqual(false);
expect(info.entryDir).assertEqual("/data/app/el1/bundle/public/com.example.third1/com.example.third1.entry");
expect(info.supportedModes).assertEqual(0);
expect(info.process).assertEqual("");
expect(info.process).assertEqual("com.example.third1");
expect(info.moduleSourceDirs[0]).assertEqual("/data/app/el1/bundle/public/com.example.third1/com.example.third1.entry");
expect(JSON.stringify(info.metaData)).assertEqual("{}");
expect(JSON.stringify(info.metadata)).assertEqual("{}");
......
......@@ -305,7 +305,7 @@ export default function applicationBundleJsunit() {
console.info(msg + JSON.stringify(data[i]));
expect(data[i].name).assertEqual('com.open.harmony.packagemag');
expect(data[i].codePath).assertEqual('/data/app/el1/bundle/public/com.open.harmony.packagemag');
expect(data[i].description).assertEqual('$string:mainability_description');
expect(data[i].description).assertEqual('$string:entry_description');
if (data[i].descriptionId !== 0) {
expect(data[i].descriptionId > 0).assertEqual(true);
}
......@@ -321,7 +321,7 @@ export default function applicationBundleJsunit() {
};
expect(data[i].systemApp).assertEqual(true);
expect(data[i].supportedModes).assertEqual(0);
expect(data[i].process).assertEqual("");
expect(data[i].process).assertEqual('com.open.harmony.packagemag');
expect(data[i].entryDir).assertEqual('/data/app/el1/bundle/public/com.open.harmony.packagemag' +
'/com.open.harmony.packagemag');
expect(data[i].enabled).assertEqual(true);
......
......@@ -372,7 +372,7 @@ export default function applicationBundleJsunit() {
expect(data.name).assertEqual('com.open.harmony.packagemag');
expect(data.codePath).assertEqual('/data/app/el1/bundle/public/com.open.harmony.packagemag');
expect(data.accessTokenId > 0).assertEqual(true);
expect(data.description).assertEqual('$string:mainability_description');
expect(data.description).assertEqual('$string:entry_description');
expect(data.descriptionId > 0).assertEqual(true);
expect(data.icon).assertEqual('$media:icon');
expect(data.iconId > 0).assertEqual(true);
......@@ -381,7 +381,7 @@ export default function applicationBundleJsunit() {
expect(data.labelId > 0).assertEqual(true);
expect(data.systemApp).assertEqual(true);
expect(data.supportedModes).assertEqual(0);
expect(data.process).assertEqual("");
expect(data.process).assertEqual('com.open.harmony.packagemag');
expect(data.entryDir).assertEqual('/data/app/el1/bundle/public/com.open.harmony.packagemag' +
'/com.open.harmony.packagemag');
expect(data.enabled).assertEqual(true);
......@@ -402,7 +402,7 @@ export default function applicationBundleJsunit() {
expect(data.name).assertEqual('com.open.harmony.packagemag');
expect(data.codePath).assertEqual('/data/app/el1/bundle/public/com.open.harmony.packagemag');
expect(data.accessTokenId > 0).assertEqual(true);
expect(data.description).assertEqual('$string:mainability_description');
expect(data.description).assertEqual('$string:entry_description');
expect(data.descriptionId > 0).assertEqual(true);
expect(data.icon).assertEqual('$media:icon');
expect(data.iconId > 0).assertEqual(true);
......@@ -411,7 +411,7 @@ export default function applicationBundleJsunit() {
expect(data.labelId > 0).assertEqual(true);
expect(data.systemApp).assertEqual(true);
expect(data.supportedModes).assertEqual(0);
expect(data.process).assertEqual("");
expect(data.process).assertEqual('com.open.harmony.packagemag');
expect(data.entryDir).assertEqual('/data/app/el1/bundle/public/com.open.harmony.packagemag' +
'/com.open.harmony.packagemag');
expect(data.enabled).assertEqual(true);
......
......@@ -15,6 +15,10 @@
{
"name": "description_serviceability",
"value": "hap sample empty service"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -30,6 +30,7 @@ const DIR1 = "/data/app/el1/bundle/public/com.example.myapplication1/com.example
const DIR2 = "/data/app/el1/bundle/public/com.example.myapplication2/com.example.myapplication2"
const DIR3 = "/data/app/el1/bundle/public/com.example.myapplication2/com.example.myapplication1"
const DESCRIPTION = "$string:mainability_description"
const APPLICATION_DESCRIPTION = "$string:entry_description"
let userId = 0;
describe('ActsBundleManagerTest', function () {
......@@ -66,7 +67,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.type).assertEqual("");
expect(datainfo.cpuAbi).assertEqual("");
expect(datainfo.appInfo.name).assertEqual(NAME1);
expect(datainfo.appInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.appInfo.descriptionId >= 0).assertTrue();
expect(datainfo.appInfo.icon).assertEqual("$media:icon");
expect(datainfo.appInfo.iconId >= 0).assertTrue();
......@@ -83,7 +84,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.reqPermissionDetails[0].usedScene.when).assertEqual("always");
expect(datainfo.compatibleVersion).assertEqual(5);
expect(datainfo.targetVersion).assertEqual(5);
expect(datainfo.isCompressNativeLibs).assertEqual(false);
expect(datainfo.isCompressNativeLibs).assertEqual(true);
for (let s = 0; s < datainfo.hapModuleInfos.length; s++) {
expect(datainfo.hapModuleInfos[s].name).assertEqual("com.example.myapplication1");
expect(datainfo.hapModuleInfos[s].moduleName).assertEqual("entry");
......@@ -128,7 +129,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.reqPermissionDetails.length).assertEqual(0);
expect(datainfo.extensionAbilityInfo.length).assertEqual(0);
expect(datainfo.appInfo.name).assertEqual(NAME1);
expect(datainfo.appInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.appInfo.descriptionId >= 0).assertTrue();
expect(datainfo.appInfo.icon).assertEqual("$media:icon");
expect(datainfo.appInfo.iconId >= 0).assertTrue();
......@@ -160,7 +161,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.versionName).assertLarger(0);
expect(datainfo.entryModuleName).assertEqual("entry");
expect(datainfo.appInfo.name).assertEqual(NAME1);
expect(datainfo.appInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.appInfo.descriptionId >= 0).assertTrue();
expect(datainfo.appInfo.icon).assertEqual("$media:icon");
expect(datainfo.appInfo.iconId >= 0).assertTrue();
......@@ -187,7 +188,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.versionName).assertLarger(0);
expect(datainfo.entryModuleName).assertEqual("entry");
expect(datainfo.appInfo.name).assertEqual(NAME1);
expect(datainfo.appInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.appInfo.descriptionId >= 0).assertTrue();
expect(datainfo.appInfo.icon).assertEqual("$media:icon");
expect(datainfo.appInfo.iconId >= 0).assertTrue();
......@@ -221,7 +222,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo[i].name.length).assertLarger(0);
if (datainfo[i].name == NAME1 || datainfo[i].name == NAME2
|| datainfo[i].name == NAME3 || datainfo[i].name == NAME4 || datainfo[i].name == NAME5) {
expect(datainfo[i].description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(datainfo[i].icon.length).assertLarger(0);
expect(datainfo[i].label.length).assertLarger(0);
}
......@@ -273,7 +274,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -297,7 +298,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.moduleSourceDirs.length).assertLarger(0);
expect(datainfo.moduleInfos.length).assertLarger(0);
expect(datainfo.name).assertEqual(NAME1);
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.systemApp).assertEqual(true);
......@@ -305,7 +306,7 @@ describe('ActsBundleManagerTest', function () {
expect(parseInt(datainfo.iconId)).assertLarger(0);
expect(parseInt(datainfo.labelId)).assertLarger(0);
expect(datainfo.supportedModes).assertEqual(0);
expect(datainfo.process).assertEqual("");
expect(datainfo.process).assertEqual(NAME1);
expect(datainfo.enabled).assertEqual(true);
expect(datainfo.metaData.entry[0].name).assertEqual("metaDataName");
expect(datainfo.metaData.entry[0].value).assertEqual("metaDataValue");
......@@ -336,7 +337,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -363,7 +364,7 @@ describe('ActsBundleManagerTest', function () {
expect(typeof datainfo).assertEqual(OBJECT);
expect(datainfo.name).assertEqual(NAME1);
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.descriptionId >= 0).assertTrue();
expect(parseInt(datainfo.iconId)).assertLarger(0);
......@@ -390,7 +391,7 @@ describe('ActsBundleManagerTest', function () {
expect(typeof datainfo).assertEqual(OBJECT);
expect(datainfo.name).assertEqual(NAME1);
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.descriptionId).assertLarger(0);
expect(parseInt(datainfo.iconId)).assertLarger(0);
......@@ -419,7 +420,7 @@ describe('ActsBundleManagerTest', function () {
expect(typeof datainfo).assertEqual(OBJECT);
expect(datainfo.name).assertEqual(NAME1);
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.descriptionId).assertLarger(0);
expect(parseInt(datainfo.iconId)).assertLarger(0);
......@@ -443,7 +444,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.versionName).assertLarger(0);
expect(datainfo.entryModuleName).assertEqual("entry");
expect(datainfo.appInfo.name).assertEqual(NAME2);
expect(datainfo.appInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.appInfo.descriptionId >= 0).assertTrue();
expect(datainfo.appInfo.icon).assertEqual("$media:icon");
expect(datainfo.appInfo.iconId >= 0).assertTrue();
......@@ -467,7 +468,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.versionName).assertLarger(0);
expect(datainfo.entryModuleName).assertEqual("entry");
expect(datainfo.appInfo.name).assertEqual(NAME2);
expect(datainfo.appInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.appInfo.descriptionId >= 0).assertTrue();
expect(datainfo.appInfo.icon).assertEqual("$media:icon");
expect(datainfo.appInfo.iconId >= 0).assertTrue();
......@@ -514,7 +515,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo[i].name.length).assertLarger(0);
if (datainfo[i].name == NAME1 || datainfo[i].name == NAME2
|| datainfo[i].name == NAME3 || datainfo[i].name == NAME4 || datainfo[i].name == NAME5) {
expect(datainfo[i].description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(datainfo[i].icon.length).assertLarger(0);
expect(datainfo[i].label.length).assertLarger(0);
}
......@@ -541,7 +542,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo[i].name.length).assertLarger(0);
if (datainfo[i].name == NAME1 || datainfo[i].name == NAME2
|| datainfo[i].name == NAME3 || datainfo[i].name == NAME4 || datainfo[i].name == NAME5) {
expect(datainfo[i].description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(datainfo[i].icon.length).assertLarger(0);
expect(datainfo[i].label.length).assertLarger(0);
}
......@@ -568,7 +569,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo[i].name.length).assertLarger(0);
if (datainfo[i].name == NAME1 || datainfo[i].name == NAME2
|| datainfo[i].name == NAME3 || datainfo[i].name == NAME4 || datainfo[i].name == NAME5) {
expect(datainfo[i].description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(datainfo[i].icon.length).assertLarger(0);
expect(datainfo[i].label.length).assertLarger(0);
}
......@@ -597,7 +598,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -620,7 +621,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -647,7 +648,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.moduleSourceDirs.length).assertLarger(0);
expect(datainfo.moduleInfos.length).assertLarger(0);
expect(datainfo.name).assertEqual(NAME2);
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.systemApp).assertEqual(true);
......@@ -655,7 +656,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.iconId >= 0).assertTrue();
expect(datainfo.labelId >= 0).assertTrue();
expect(datainfo.supportedModes).assertEqual(0);
expect(datainfo.process).assertEqual("");
expect(datainfo.process).assertEqual(NAME2);
expect(datainfo.enabled).assertEqual(true);
expect(datainfo.moduleSourceDirs.length).assertLarger(0);
for (let j = 0; j < datainfo.moduleInfos.length; j++) {
......@@ -678,7 +679,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -702,7 +703,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -730,10 +731,9 @@ describe('ActsBundleManagerTest', function () {
expect(typeof datainfo).assertEqual(OBJECT);
expect(datainfo.name).assertEqual(NAME2);
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.name).assertEqual(NAME2);
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.descriptionId >= 0).assertTrue();
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.iconId >= 0).assertTrue();
......@@ -757,7 +757,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -779,7 +779,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(datainfo[i].description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -801,7 +801,7 @@ describe('ActsBundleManagerTest', function () {
expect(data[i].appInfo.name.length).assertLarger(0);
if (data[i].name == NAME1 || data[i].name == NAME2
|| data[i].name == NAME3 || data[i].name == NAME4 || data[i].name == NAME5) {
expect(data[i].appInfo.description.length).assertLarger(0);
expect(data[i].appInfo.description.length >= 0).assertTrue();
expect(data[i].appInfo.icon.length).assertLarger(0);
expect(data[i].appInfo.label.length).assertLarger(0);
}
......@@ -830,7 +830,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.moduleSourceDirs.length).assertLarger(0);
expect(datainfo.moduleInfos.length).assertLarger(0);
expect(datainfo.name).assertEqual(NAME2);
expect(datainfo.description).assertEqual(DESCRIPTION);
expect(datainfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.icon).assertEqual("$media:icon");
expect(datainfo.label).assertEqual("$string:app_name");
expect(datainfo.systemApp).assertEqual(true);
......@@ -838,7 +838,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.iconId >= 0).assertTrue();
expect(datainfo.labelId >= 0).assertTrue();
expect(datainfo.supportedModes).assertEqual(0);
expect(datainfo.process).assertEqual("");
expect(datainfo.process).assertEqual(NAME2);
expect(datainfo.enabled).assertEqual(true);
expect(datainfo.moduleSourceDirs.length).assertLarger(0);
for (let j = 0; j < datainfo.moduleInfos.length; j++) {
......@@ -1032,7 +1032,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.launchMode).assertEqual(demo.LaunchMode.STANDARD);
expect(datainfo.permissions[0]).assertEqual("com.permission.BMS_PERMISSION_CAMERA");
expect(datainfo.applicationInfo.name).assertEqual(NAME1);
expect(datainfo.applicationInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.applicationInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.applicationInfo.descriptionId >= 0).assertTrue();
expect(datainfo.applicationInfo.icon).assertEqual("$media:icon");
expect(datainfo.applicationInfo.iconId >= 0).assertTrue();
......@@ -1077,7 +1077,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.orientation).assertEqual(1);
expect(datainfo.launchMode).assertEqual(demo.LaunchMode.SINGLETON);
expect(datainfo.applicationInfo.name).assertEqual(NAME2);
expect(datainfo.applicationInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.applicationInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.applicationInfo.descriptionId >= 0).assertTrue();
expect(datainfo.applicationInfo.icon).assertEqual("$media:icon");
expect(datainfo.applicationInfo.iconId >= 0).assertTrue();
......@@ -1114,7 +1114,7 @@ describe('ActsBundleManagerTest', function () {
expect(datainfo.moduleName).assertEqual("entry");
expect(datainfo.bundleName).assertEqual(NAME3);
expect(datainfo.applicationInfo.name).assertEqual(NAME3);
expect(datainfo.applicationInfo.description).assertEqual(DESCRIPTION);
expect(datainfo.applicationInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(datainfo.applicationInfo.descriptionId >= 0).assertTrue();
expect(datainfo.applicationInfo.icon).assertEqual("$media:icon");
expect(datainfo.applicationInfo.iconId >= 0).assertTrue();
......@@ -1214,7 +1214,7 @@ describe('ActsBundleManagerTest', function () {
expect(dataInfo.versionName).assertLarger(0);
expect(dataInfo.entryModuleName).assertEqual("entry");
expect(dataInfo.appInfo.name).assertEqual(NAME1);
expect(dataInfo.appInfo.description).assertEqual(DESCRIPTION);
expect(dataInfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(dataInfo.appInfo.descriptionId >= 0).assertTrue();
expect(dataInfo.appInfo.icon).assertEqual("$media:icon");
expect(dataInfo.appInfo.iconId >= 0).assertTrue();
......@@ -1227,7 +1227,7 @@ describe('ActsBundleManagerTest', function () {
expect(dataInfo.reqPermissionDetails.length).assertEqual(0);
expect(dataInfo.compatibleVersion).assertEqual(5);
expect(dataInfo.targetVersion).assertEqual(5);
expect(dataInfo.isCompressNativeLibs).assertEqual(false);
expect(dataInfo.isCompressNativeLibs).assertEqual(true);
for (let s = 0; s < dataInfo.hapModuleInfos.length; s++) {
expect(dataInfo.hapModuleInfos[s].name).assertEqual("com.example.myapplication1");
expect(dataInfo.hapModuleInfos[s].moduleName).assertEqual("entry");
......@@ -1261,7 +1261,7 @@ describe('ActsBundleManagerTest', function () {
expect(dataInfo.versionName).assertLarger(0);
expect(dataInfo.entryModuleName).assertEqual("entry");
expect(dataInfo.appInfo.name).assertEqual(NAME1);
expect(dataInfo.appInfo.description).assertEqual(DESCRIPTION);
expect(dataInfo.appInfo.description).assertEqual(APPLICATION_DESCRIPTION);
expect(dataInfo.appInfo.descriptionId >= 0).assertTrue();
expect(dataInfo.appInfo.icon).assertEqual("$media:icon");
expect(dataInfo.appInfo.iconId >= 0).assertTrue();
......@@ -1274,7 +1274,7 @@ describe('ActsBundleManagerTest', function () {
expect(dataInfo.reqPermissionDetails.length).assertEqual(0);
expect(dataInfo.compatibleVersion).assertEqual(5);
expect(dataInfo.targetVersion).assertEqual(5);
expect(dataInfo.isCompressNativeLibs).assertEqual(false);
expect(dataInfo.isCompressNativeLibs).assertEqual(true);
for (let s = 0; s < dataInfo.hapModuleInfos.length; s++) {
expect(dataInfo.hapModuleInfos[s].name).assertEqual("com.example.myapplication1");
expect(dataInfo.hapModuleInfos[s].moduleName).assertEqual("entry");
......
......@@ -171,6 +171,7 @@
"grantMode": "system_grant",
"availableScope": ["signature"]
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -71,6 +71,7 @@
"description": "BMS_PERMISSION_MUSIC permission in detail",
"label": "BMS_PERMISSION_MUSIC permission"
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -70,6 +70,7 @@
"description": "BMS_PERMISSION_CAMERA permission in detail",
"label": "BMS_PERMISSION_CAMERA permission"
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -102,6 +102,7 @@
"value":"metaDataValue",
"extra":"$string:app_name"
}]
}
},
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -69,6 +69,7 @@
"description": "BMS_PERMISSION_WECHAT permission in detail",
"label": "BMS_PERMISSION_WECHAT permission"
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -76,6 +76,7 @@
"description": "BMS_PERMISSION_MUSIC permission in detail",
"label": "BMS_PERMISSION_MUSIC permission"
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
......@@ -69,6 +69,7 @@
"description": "BMS_PERMISSION_CAMERA permission in detail",
"label": "BMS_PERMISSION_CAMERA permission"
}
]
],
"description":"$string:entry_description"
}
}
\ No newline at end of file
......@@ -7,6 +7,10 @@
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
},
{
"name": "entry_description",
"value": "entry_description"
}
]
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册