未验证 提交 68b5f90a 编写于 作者: O openharmony_ci 提交者: Gitee

!5203 【窗口子系统】增加属性用例

Merge pull request !5203 from hekun/monthly_20220816
......@@ -46,7 +46,8 @@ export default function windowCallbackTest(context, windowStage, abilityStorage)
'TYPE_KEYGUARD': 5,
'TYPE_VOLUME_OVERLAY': 6,
'TYPE_NAVIGATION_BAR': 7,
'TYPE_FLOAT': 8
'TYPE_FLOAT': 8,
'TYPE_FLOAT_CAMERA':9
}
var windowLayoutModeArr = [];
var windowLayoutModeDic = {
......
......@@ -45,7 +45,8 @@ export default function windowPromiseTest(context, windowStage, abilityStorage)
'TYPE_KEYGUARD': 5,
'TYPE_VOLUME_OVERLAY': 6,
'TYPE_NAVIGATION_BAR': 7,
'TYPE_FLOAT': 8
'TYPE_FLOAT': 8,
'TYPE_FLOAT_CAMERA':9
}
var windowLayoutModeArr = [];
var windowLayoutModeDic = {
......
......@@ -176,6 +176,7 @@ describe('window_test', function () {
expect(wnd != null).assertTrue();
wnd.getAvoidArea(window.AvoidAreaType.TYPE_SYSTEM).then((data) => {
console.log('windowTest getAvoidAreaTest1 wnd.getAvoidArea success, data :' + JSON.stringify(data));
expect(data.visible).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......@@ -205,6 +206,7 @@ describe('window_test', function () {
expect(wnd != null).assertTrue();
wnd.getAvoidArea(window.AvoidAreaType.TYPE_CUTOUT).then((data) => {
console.log('windowTest getAvoidAreaTest2 wnd.getAvoidArea success, data :' + JSON.stringify(data));
expect(!data.visible).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......@@ -234,6 +236,7 @@ describe('window_test', function () {
expect(wnd != null).assertTrue();
wnd.getAvoidArea(avoidAreaType).then((data) => {
console.log('windowTest getAvoidAreaTest3 wnd.getAvoidArea success, data :' + JSON.stringify(data));
expect(data.visible).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......@@ -267,6 +270,7 @@ describe('window_test', function () {
expect().assertFail();
done();
} else {
expect(data.visible).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......@@ -293,6 +297,7 @@ describe('window_test', function () {
expect().assertFail();
done();
} else {
expect(!data.visible).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......@@ -324,6 +329,7 @@ describe('window_test', function () {
expect().assertFail();
done();
} else {
expect(data.visible).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......@@ -3489,6 +3495,7 @@ describe('window_test', function () {
expect().assertFail();
done();
} else {
expect(data.visible).assertTrue();
expect(data.topRect != null).assertTrue();
expect(data.rightRect != null).assertTrue();
expect(data.bottomRect != null).assertTrue();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册