提交 ba29bbc2 编写于 作者: 华华小仙女

修改setWindowMode错误码401->1300002

Signed-off-by: N华华小仙女 <zhurong18@h-partners.com>
上级 682defe8
...@@ -2305,7 +2305,7 @@ export default function displayAndWindowRefactorInterfaceTest(context, windowSta ...@@ -2305,7 +2305,7 @@ export default function displayAndWindowRefactorInterfaceTest(context, windowSta
expect(!!tempWnd).assertTrue(); expect(!!tempWnd).assertTrue();
await tempWnd.setWindowMode(ohosWindow.WindowMode.UNDEFINED).catch(async (err) => { await tempWnd.setWindowMode(ohosWindow.WindowMode.UNDEFINED).catch(async (err) => {
console.error(msgStr + 'Failed to set the window mode. Cause: ' + JSON.stringify(err)); console.error(msgStr + 'Failed to set the window mode. Cause: ' + JSON.stringify(err));
expect(err.code == 401).assertTrue(); expect(err.code == 1300002).assertTrue();
await tempWnd.destroyWindow() await tempWnd.destroyWindow()
console.log(msgStr + 'tempWnd.setWindowMode failed ' + 'finished'); console.log(msgStr + 'tempWnd.setWindowMode failed ' + 'finished');
done(); done();
...@@ -2341,7 +2341,7 @@ export default function displayAndWindowRefactorInterfaceTest(context, windowSta ...@@ -2341,7 +2341,7 @@ export default function displayAndWindowRefactorInterfaceTest(context, windowSta
console.log(msgStr + 'currentType: ' + tempType) console.log(msgStr + 'currentType: ' + tempType)
console.error(msgStr + 'Failed to set the window mode. Cause: ' + JSON.stringify(err)); console.error(msgStr + 'Failed to set the window mode. Cause: ' + JSON.stringify(err));
try { try {
expect(err.code == 401).assertTrue(); expect(err.code == 1300002).assertTrue();
} catch (error) { } catch (error) {
console.info(`ohosWindow.createWindow catch error: ${JSON.stringify(error)}`) console.info(`ohosWindow.createWindow catch error: ${JSON.stringify(error)}`)
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册