提交 5b477030 编写于 作者: S SoftSquirrel

Description:bms xts fix

Feature or Bugfix: Bugfix
Binary Source: No
Signed-off-by: NSoftSquirrel <xuhao47@huawei.com>
上级 ae6cf5f1
......@@ -18,7 +18,6 @@ import demo from '@ohos.bundle'
import featureAbility from '@ohos.ability.featureability'
import abilityManager from '@ohos.app.abilityManager'
import commonEvent from '@ohos.commonevent'
import missionmanager from '@ohos.application.missionManager'
const PATH = "/data/"
const ERROR = "error.hap"
......@@ -46,35 +45,6 @@ var subscriberInfoEvent_0100 = {
};
describe('ActsBundleManagerUninstall', function () {
afterEach(async (done) => {
var testMissionId;
testMissionId = await getMissionId();
console.debug('======>ActsBundleManagerUninstall afterEach testMissionId<=======' + testMissionId);
if (testMissionId != -1) {
await missionmanager.moveMissionToFront(testMissionId);
}
done();
})
function getMissionId() {
return new Promise(async (resolve, reject) => {
var numMax = 1024;
var missionId = -1;
var missionInfos = await missionmanager.getMissionInfos('', numMax);
console.debug('getMissionId result: ' + missionInfos.length);
for (let i = 0; i < missionInfos.length; i++) {
console.debug('getMissionId result: ' + i + '= ' + JSON.stringify(missionInfos[i]))
if ((missionInfos[i].want.abilityName == "com.example.actsbundlemanageruninstall.MainAbility") &&
(missionInfos[i].runningState == 0)) {
missionId = missionInfos[i].missionId;
break;
}
}
console.debug('======>getMissionId resolve missionId<=======' + missionId);
resolve(missionId);
})
}
/**
* @tc.number uninstall_0100
* @tc.name BUNDLE::uninstall
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册