diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/List.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/List.test.ets index 97e418dd9be78f6daebf174d1ebb1a9e2ebf0241..18287ce911b9efe87f64451b28063a0a5ef67c70 100644 --- a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/List.test.ets +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/List.test.ets @@ -15,6 +15,14 @@ import demoTest from './Demo.test' import UIAttributeFontInterface001 from './UIAttributeFontInterfaceTest/UIAttributeFontInterface001.test' +import UIComponentDividerBlankLayout from './UIComponentDividerBlankLayout/UIComponentDividerBlankLayout.test' +import UIComponentDividerDividerInterface from './UIComponentDividerDividerInterface/UIComponentDividerDividerInterface.test' +import UIComponentDividerDividerLayout from './UIComponentDividerDividerLayout/UIComponentDividerDividerLayout.test' +import UIComponentDividerStyle from './UIComponentDividerStyle/UIComponentDividerStyle.test' +import UIComponentLayoutFlexInterface from './UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface.test' +import UIComponentTextRefactorAdjustment from './UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment.test' +import UIComponentTextTextareEnhances from './UIComponentTextTextareEnhances/UIComponentTextTextareEnhances.test' +import UIAttributeFontInterface001 from './UIAttributeFontInterfaceTest/UIAttributeFontInterface001.test' import UIAttributeFontInterfaceColor from './UIAttributeFontInterfaceTest/UIAttributeFontInterfaceColor.test' import UIAttributeFontInterfaceFontFamily from './UIAttributeFontInterfaceTest/UIAttributeFontInterfaceFontFamily.test' import UIAttributeFontInterfaceSize from './UIAttributeFontInterfaceTest/UIAttributeFontInterfaceSize.test' @@ -50,6 +58,13 @@ import UIComponentCreateColor from './UIComponentCreateColorTest/UIComponentCrea export default function testsuite() { demoTest(); UIAttributeFontInterface001(); + UIComponentDividerBlankLayout(); + UIComponentDividerDividerInterface(); + UIComponentDividerDividerLayout(); + UIComponentDividerStyle(); + UIComponentLayoutFlexInterface(); + UIComponentTextRefactorAdjustment(); + UIComponentTextTextareEnhances(); UIAttributeFontInterfaceColor(); UIAttributeFontInterfaceFontFamily(); UIAttributeFontInterfaceSize(); diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..abb60f5d3e12f7e9e3560201971784e0a8d0016a --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout.test.ets @@ -0,0 +1,408 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentDividerBlankLayout() { + + describe('UIComponentDividerBlankLayout', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0010 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0010 + * @tc.desc The width of the Row component is set, the Blank component is set only to min, + * and the width of the Row component is set to be greater than the spindle length of all subcomponents + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0010', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout001 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout001") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout001 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0020 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0020 + * @tc.desc The width of the Row component is set, the Blank component is set only in min, + * and the width of the Row component is set less than the spindle length of all subcomponents + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0020', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout002 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout002") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout002 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0030 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0030 + * @tc.desc The width of the Row component is set, the width of the Blank component is set only, + * and the width of the Row component is set to be greater than the spindle length of all subcomponents + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0030', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout003 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout003") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout003 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0040 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0040 + * @tc.desc The width of the Row component is set, the width of the Blank component is set only, + * and the width of the Row component is set less than the spindle length of all subcomponents + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0040', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout004 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout004") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout004 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0050 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0050 + * @tc.desc The width of the Row component is set, the width of the Blank component is set to min and width(min { + Logger.info('TEST', `UIComponentDividerBlankLayout005 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout005") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout005 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0060 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0060 + * @tc.desc The width of the Row component is set, the width of the Blank component is set to min and width(min { + Logger.info('TEST', `UIComponentDividerBlankLayout006 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout006") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout006 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0070 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0070 + * @tc.desc The width of the Row component is set, the width of the Blank component is set to min and width(min>width), + * and the width of the Row component is set to be greater than the spindle length of all subcomponents + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0070', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout007 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout007") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout007 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0080 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0080 + * @tc.desc The width of the Row component is set, the width of the Blank component is set to min and width(min>width), + * and the width of the Row component is set to be less than the spindle length of all subcomponents + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0080', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout008 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout008") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout008 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0090 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0090 + * @tc.desc The Row component sets the width, and only one Blank component in the Row component is displayed + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0090', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout009 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout009") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout009 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0100 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0100 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set only min, and the width of the Row component is set greater than the spindle length of all sub-components + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0100', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout010 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout010") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0110 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0110 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set only min, and the width of the Row component is set less than the spindle length of all sub-components + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0110', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout011 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout011") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout011 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0120 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0120 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set only width, and the width of the Row component is set less than the main axis length of the Text component + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0120', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout012 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout012") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout012 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0130 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0130 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set min and width, and the width of the Row component is set to be greater than the spindle length of all sub-components (min { + Logger.info('TEST', `UIComponentDividerBlankLayout013 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout013") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout013 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0140 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0140 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set min and width, and the width of the Row component is set to be greater than the spindle length of all sub-components (min>width). + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0140', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout014 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout014") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout014 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0150 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0150 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set min and width, and the width of the Row component is set less than the spindle length of all sub-components (min { + Logger.info('TEST', `UIComponentDividerBlankLayout015 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout015") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout015 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0160 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0160 + * @tc.desc The width of the Row component is set, the sub-components are Text and Blank components, + * the Blank component is set min and width, and the width of the Row component is set less than the spindle length of all sub-components (min>width). + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0160', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout016 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout016") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout016 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0170 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0170 + * @tc.desc The Row component sets the width, and the sub-components are multiple Blank components. + * The Blank component does not set min and width + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0170', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout017 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout017") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout017 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0180 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0180 + * @tc.desc The Row component sets the width, the child components are multiple Blank components, + * and the Blank component sets only one width + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0180', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout018 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout018") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout018 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0190 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0190 + * @tc.desc The width of the Row component is set, and the sub-components are multiple Blank components, + * and the Blank components are only set to different min + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0190', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout019 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout019") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout019 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0200 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0200 + * @tc.desc The width of the Row component is set, the sub-components are multiple Blank components, + * the Blank components are set only for different min, and the width of the Row component is set to be greater than the spindle length of all sub-components + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0200', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout020 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout020") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout020 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0210 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0210 + * @tc.desc The width of the Row component is set, the sub-components are multiple Blank components, + * the Blank components are set only for different min, and the width of the Row component is set less than the spindle length of all sub-components + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0210', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout021 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout021") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout021 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0220 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0220 + * @tc.desc The width of the Row component is set, the sub-component is multiple Blank components, + * the min and width of the Blank component are set, and the width of the Row component is set to be greater than + * the spindle length of all sub-components (min { + Logger.info('TEST', `UIComponentDividerBlankLayout022 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout022") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout022 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0230 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0230 + * @tc.desc The width of the Row component is set, the sub-component is multiple Blank components, + * the Blank component is set min and width, and the min and width of the three blanks are set to the same value + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_BLANK_LAYOUT_0230', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerBlankLayout023 start.`); + Settings.createWindow("testability/pages/UIComponentDividerBlankLayout/UIComponentDividerBlankLayout023") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerBlankLayout023 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerDividerInterface/UIComponentDividerDividerInterface.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerDividerInterface/UIComponentDividerDividerInterface.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..59166109a4740e67d0db5b11cb2e7cfbce62949c --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerDividerInterface/UIComponentDividerDividerInterface.test.ets @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentDividerDividerInterface() { + + describe('UIComponentDividerDividerInterface', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_INTERFACE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_INTERFACE_0070 + * @tc.desc Divider component strokeWidth is set several times + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_INTERFACE_0070', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerDividerInterface007 start.`); + Settings.createWindow("testability/pages/UIComponentDividerDividerInterface/UIComponentDividerDividerInterface007") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerDividerInterface007 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerDividerLayout/UIComponentDividerDividerLayout.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerDividerLayout/UIComponentDividerDividerLayout.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..72efa1d29c809d8cbf6a8ee665c4bd8ae0d70535 --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerDividerLayout/UIComponentDividerDividerLayout.test.ets @@ -0,0 +1,85 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentDividerDividerLayout() { + + describe('UIComponentDividerDividerLayout', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0010 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0010 + * @tc.desc Divider do not set width or height + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0010', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerDividerLayout001 start.`); + Settings.createWindow("testability/pages/UIComponentDividerDividerLayout/UIComponentDividerDividerLayout001") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerDividerLayout001 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0020 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0020 + * @tc.desc Divider Specifies the width + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0020', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerDividerLayout002 start.`); + Settings.createWindow("testability/pages/UIComponentDividerDividerLayout/UIComponentDividerDividerLayout002") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerDividerLayout002 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0030 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0030 + * @tc.desc Divider Set a height + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_DIVIDER_LAYOUT_0030', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerDividerLayout003 start.`); + Settings.createWindow("testability/pages/UIComponentDividerDividerLayout/UIComponentDividerDividerLayout003") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerDividerLayout003 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerStyle/UIComponentDividerStyle.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerStyle/UIComponentDividerStyle.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..bcb8f8ca0ab8bc73f3df7ae95ba504c093bf6d12 --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentDividerStyle/UIComponentDividerStyle.test.ets @@ -0,0 +1,145 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentDividerStyle() { + + describe('UIComponentDividerStyle', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0290 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0290 + * @tc.desc Blankcolor passes in color.blue + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0290', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle029 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle029") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle029 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0300 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0300 + * @tc.desc The Blankcolor is passed in #0000ff + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0300', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle030 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle030") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle030 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0310 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0310 + * @tc.desc Blankcolor rgb(0, 0, 255) + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0310', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle031 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle031") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle031 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0320 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0320 + * @tc.desc The Blankcolor is passed 0x0000ff + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0320', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle032 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle032") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle032 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0330 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0330 + * @tc.desc Blankcolor refers to resources through resources + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0330', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle033 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle033") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle033 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0340 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0340 + * @tc.desc Blankcolor passed in an illegal string + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0340', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle034 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle034") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle034 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0350 + * @tc.name SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0350 + * @tc.desc Blank sets the background color + */ + it('SUB_ACE_UI_COMPONENT_DIVIDER_STYLE_0350', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentDividerStyle035 start.`); + Settings.createWindow("testability/pages/UIComponentDividerStyle/UIComponentDividerStyle035") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentDividerStyle035 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..f6ce934133119bd84f027e4f7ab89d950fb843ac --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface.test.ets @@ -0,0 +1,1057 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentLayoutFlexInterface() { + + describe('UIComponentLayoutFlexInterface', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0010 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0010 + * @tc.desc Layout arrangement, spindle arrangement: + * The parent component has a fixed layout with four subelements, + * justifyContent attribute value is set to FlexAlign.Center for the parent component + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0010', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface001 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface001") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface001 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0020 + * @tc.desc Layout arrangement, spindles arrangement: Parent component layout fixed, + * layout four child subelements, space value non-0 positive, + * justifyContent attribute value for the parent component was set FlexAlign.End + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0020', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface002 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface002") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface002 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0030 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0030 + * @tc.desc Layout arrangement, spindle arrangement: The parent component layout is fixed, + * layout four child child elements, space value is non-0 positive, + * justifyContent attribute value is set to FlexAlign.SpaceAround for the parent component + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0030', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface003 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface003") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface003 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0040 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0040 + * @tc.desc Layout arrangement, spindle arrangement: The parent component layout is fixed, + * the layout of four child child elements, the space value is non-0 positive, + * justifyContent attribute value is FlexAlign.SpaceBetween for the parent component + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0040', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface004 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface004") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface004 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0050 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0050 + * @tc.desc Layout arrangement, spindle arrangement: The parent component layout is fixed, + * the layout of four child child elements, the space value is non-0 positive, + * justifyContent attribute value is set to FlexAlign.SpaceEvenly for the parent component + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0050', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface005 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface005") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface005 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0060 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0060 + * @tc.desc Layout arrangement, spindle arrangement: + * The parent component has a fixed layout with four child subelements, + * justifyContent is set to FlexAlign.Start for the parent component + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0060', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface006 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface006") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface006 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0070 + * @tc.desc The alignSelf property is set to ItemAlign.Auto. + * The AlignSelf property is set to itemalign.auto for the child elements + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0070', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface007 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface007") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface007 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0080 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0080 + * @tc.desc Layout arrangement, cross axis arrangement: the parent component layout is fixed, + * layout four child elements, space value is non-0 positive, + * set the alignSelf attribute value for the child element to itemAligne.baseline + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0080', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface008 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface008") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface008 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0090 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0090 + * @tc.desc The alignSelf property is set to ItemAlign.Center. + * The AlignSelf property is set to itemalign.center. + * The AlignSelf property Alignself is set to itemalign.center + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0090', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface009 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface009") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface009 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0100 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0100 + * @tc.desc The alignSelf property is set to ItemAlign.End. + * The AlignSelf property is set to itemalign.end. + * The AlignSelf property sets the AlignSelf property to itemalign.end + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0100', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface010 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface010") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0110 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0110 + * @tc.desc The alignSelf property is set to ItemAlign.Start. + * The AlignSelf property is set to itemalign.start. + * The AlignSelf property sets the AlignSelf property to itemalign.start + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0110', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface011 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface011") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface011 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0120 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0120 + * @tc.desc The alignSelf property is set to ItemAlign.Stretch. + * The AlignSelf property is set to itemalign.stretch. + * The AlignSelf property Alignself is set to itemalign.stretch + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0120', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface012 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface012") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface012 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0190 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0190 + * @tc.desc The alignContent property is set to FlexAlign.Center. + * The Aligncontent property is set to flexalign.center. + * The AlignContent property is set to flexAlign.center + * when the parent component is aligned with four child elements, the space value is non-zero, + * the wrap property is FlexWrap.Wrap, there is more space in the alignContent axis + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0190', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface019 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface019") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface019 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0200 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0200 + * @tc.desc The alignContent property is set to FlexAlign.End. + * The Aligncontent property is set to flexalign.end. + * The AlignContent property is aligned to flexAlign.end + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0200', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface020 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface020") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface020 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0210 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0210 + * @tc.desc The alignContent property is aligned to FlexAlign.SpaceAround. + * The AlignContent property is set to flexAlign.spacearound. The AlignContent property is aligned to flexAlign.spacearound + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0210', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface021 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface021") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface021 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0220 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0220 + * @tc.desc The alignContent property is set to FlexAlign.SpaceBetween. + * The Aligncontent property is set to flexalign.spacebetween. The AlignContent property is set to flexalign.spacebetween + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0220', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface022 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface022") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface022 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0230 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0230 + * @tc.desc The alignContent property is set to FlexAlign.SpaceEvenly. + * The Aligncontent property is set to flexalign.spaceevenly. The AlignContent property is set to flexalign.spaceevenly + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0230', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface023 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface023") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface023 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0240 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0240 + * @tc.desc The alignContent property is set to FlexAlign.Start. + * The Aligncontent property is set to flexalign.start. The AlignContent property is aligned to flexalign.start + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0240', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface024 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface024") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface024 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0250 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0250 + * @tc.desc The parent container and four child elements are arranged. + * The sum of the principal axes of the child elements is greater than the principal axes of the container. + * The wrap property is FlexWrap.Wrap and the Direction property is FlexDirection.Column&& Direction.rtl + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0250', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface025 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface025") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface025 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0260 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0260 + * @tc.desc Layout the parent container and the four child, + * child elements spindle's size is greater than the sum of container size, wrap attributes for FlexWrap. Wrap, + * set the direction attribute to FlexDirection. ColumnReverse && direction. The Rtl, to take effect + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0260', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface026 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface026") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface026 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0270 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0270 + * @tc.desc Layout of the parent container and the four child, child elements spindle's size is greater than the sum of container size, + * wrap attributes for FlexWrap. Wrap, set the direction attribute to FlexDirection. ColumnReverse, to take effect + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0270', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface027 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface027") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface027 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0280 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0280 + * @tc.desc The parent container and four child elements are arranged. + * The sum of the main axes of the child elements is greater than the main axes of the container. + * The wrap property is FlexWrap.Wrap and the direction property is FlexDirection.Column + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0280', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface028 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface028") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface028 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0290 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0290 + * @tc.desc The parent container and four child elements are arranged. + * The sum of the principal axes of the child elements is greater than the principal axes of the container. + * The wrap property is FlexWrap.Wrap and the Direction property is FlexDirection.Row&& Direction.rtl + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0290', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface029 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface029") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface029 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0300 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0300 + * @tc.desc The parent container and four child elements are arranged. + * The sum of the child element spindles is greater than the container spindles. The wrap attribute is FlexWrap.Wrap, + * and the Direction attribute is FlexDirection.RowReverse&&Direction.Rtl + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0300', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface030 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface030") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface030 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0310 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0310 + * @tc.desc The parent container and four child elements are arranged. + * The sum of the child element spindles is greater than the container spindles. + * The wrap attribute is FlexWrap.Wrap and the direction attribute is FlexDirection.RowReverse + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0310', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface031 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface031") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface031 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0320 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0320 + * @tc.desc The parent container and four child elements are arranged. + * The sum of the principal axes of the child elements is greater than the principal axes of the container. + * The wrap property is FlexWrap.Wrap and the direction property is FlexDirection.Row + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0320', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface032 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface032") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface032 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0330 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0330 + * @tc.desc Lay out the parent container with four child elements, + * the sum of the child element spindle sizes is greater than the container spindle sizes, + * set the wrap property to FlexWrap.NoWrap to take effect + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0330', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface033 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface033") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface033 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0340 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0340 + * @tc.desc Layout parent container and four child elements, + * the sum of child element spindles size is greater than the container spindles size, + * set the wrap property to FlexWrap.WrapReverse takes effect + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0340', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface034 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface034") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface034 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0350 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0350 + * @tc.desc Layout parent container and four child elements, + * the sum of the child element spindle size is greater than the container spindle size, + * set the wrap property to FlexWrap.Wrap effect + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0350', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface035 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface035") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface035 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0360 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0360 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * the layout of four child elements, and the layoutWeight setting value is between 0 and 1 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0360', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface036 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface036") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface036 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0370 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0370 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, four child elements do not set flexGrow + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0370', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface037 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface037") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface037 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0380 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0380 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, four child elements set flexGrow 4, 3, 2, 1 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0380', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface038 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface038") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface038 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0390 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0390 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, four child elements set flexGrow to null + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0390', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface039 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface039") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface039 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0400 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0400 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, layout four child elements, + * child elements 1, 2, 3, 4 set respectively.layoutWeight(4).layoutWeight(3).layoutWeight(2).layoutWeight(1) + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0400', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface040 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface040") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0410 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0410 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, layout four child elements, + * child elements 1, 2, 3, 4 set respectively.layoutWeight(" 4 ").layoutWeight(" 2 ").layoutWeight(" 1 "). + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0410', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface041 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface041") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface041 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0420 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0420 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, layout four child elements, + * child elements 1 and 2 are set respectively.layoutWeight(3) and.Layoutweight (2), child elements 3 and 4 are not set + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0420', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface042 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface042") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface042 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0430 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0430 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, layout four child elements, + * child elements 1 and 2 set layoutWeight(" 3 ") and.layoutWeight(" 2 "), child elements :3, 4 are not set + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0430', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface043 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface043") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface043 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0440 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0440 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child element 1 set flexBasis to 0 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0440', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface044 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface044") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface044 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0450 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0450 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child element 1 set flexBasis to 100 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0450', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface045 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface045") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface045 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0460 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0460 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child element 1 set flexBasis to 200fp + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0460', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface046 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface046") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface046 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0470 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0470 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child element 1 set flexBasis to 200lpx + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0470', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface047 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface047") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface047 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0480 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0480 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child element 1 set flexBasis to 200px + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0480', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface048 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface048") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface048 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0490 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0490 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, child element 1 set flexBasis to 200vp + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0490', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface049 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface049") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface049 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0500 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0500 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, child element 1 set flexBasis to auto + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0500', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface050 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface050") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface050 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0510 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0510 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, layout four child elements, + * child element 1 set layoutWeight (≥1), the rest of the child elements are not set + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0510', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface051 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface051") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface051 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0520 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0520 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements 3 and 4 set flexShink value to 1 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0520', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface052 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface052") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface052 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0530 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0530 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, child elements do not set flexBasis attribute + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0530', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface053 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface053") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface053 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0540 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0540 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, child elements do not set flexShink attribute + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0540', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface054 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface054") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface054 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0550 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0550 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set both flexGrow/flexGrow and layoutWeight + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0550', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface055 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface055") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface055 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0560 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0560 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexGrow/flexShink and layoutWeight + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0560', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface056 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface056") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface056 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0570 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0570 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, child elements set flexBasis to -5 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0570', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface057 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface057") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface057 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0580 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0580 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexBasis to null + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0580', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface058 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface058") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface058 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0590 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0590 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexBasis undefined + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0590', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface059 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface059") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface059 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0600 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0600 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexGrow to -5 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0600', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface060 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface060") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface060 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0610 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0610 + * @tc.desc Elasticity and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexGrow to undefined + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0610', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface061 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface061") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface061 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0620 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0620 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexShink to -5 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0620', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface062 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface062") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface062 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0630 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0630 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexShink to null + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0630', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface063 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface063") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface063 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0640 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0640 + * @tc.desc Elasticity and layout priority, parent container layout fixed, + * layout four child elements, child elements set flexShink to undefined + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0640', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface064 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface064") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface064 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0650 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0650 + * @tc.desc Flexibility and layout priority, the parent container layout is fixed, + * layout four child elements, child elements set the layoutWeight value to -10 + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0650', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface065 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface065") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface065 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0660 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0660 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set the layoutWeight value to null + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0660', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface066 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface066") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface066 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0670 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0670 + * @tc.desc Elastic ability and layout priority, the parent container layout is fixed, + * the layout of four child elements, the child element set layoutWeight value is undefined + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0670', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface067 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface067") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface067 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0680 + * @tc.name SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0680 + * @tc.desc Flexibility and layout priority, parent container layout fixed, + * layout four child elements, child elements set layoutWeight value to "aaa" + */ + it('SUB_ACE_UI_COMPONENT_LAYOUT_FLEX_INTERFACE_0680', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentLayoutFlexInterface068 start.`); + Settings.createWindow("testability/pages/UIComponentLayoutFlexInterface/UIComponentLayoutFlexInterface068") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentLayoutFlexInterface068 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..03682116aad832c691d743ac80872f0987d697c2 --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment.test.ets @@ -0,0 +1,175 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentTextRefactorAdjustment() { + + describe('UIComponentTextRefactorAdjustment', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0010 + * @tc.desc inline mode Empty text, toggles the input box + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0010', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment001 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment001") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment001 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0060 + * @tc.desc Click the Clear button and modify the prompt text style + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0060', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment006 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment006") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment006 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0080 + * @tc.desc textarea scroll bar verification + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0080', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment008 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment008") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment008 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0240 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0240 + * @tc.desc password mode sets the tail alignment + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0240', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment024 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment024") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment024 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0250 + * @tc.desc In phonenumber mode, enter * and # + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0250', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment025 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment025") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment025 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0390 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0390 + * @tc.desc Set the text style to italics + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0390', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment039 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment039") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment039 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0400 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0400 + * @tc.desc Set the search button text to be too long + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0400', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment040 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment040") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0410 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0410 + * @tc.desc Set the bottom alignment of text and set the number of characters displayed + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0410', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment041 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment041") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment041 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0430 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0430 + * @tc.desc Set the text box width to empty + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0430', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextRefactorAdjustment043 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustment/UIComponentTextRefactorAdjustment043") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextRefactorAdjustment043 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances.test.ets b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances.test.ets new file mode 100644 index 0000000000000000000000000000000000000000..e702e2d2014ae01759e6ec4ab0adf9a3b8cebc96 --- /dev/null +++ b/function/ui_compare/uicompare/entry/src/ohosTest/ets/test/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances.test.ets @@ -0,0 +1,762 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development 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 { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' + +export default function UIComponentTextTextareEnhances() { + + describe('UIComponentTextTextareEnhances', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0100 + * @tc.desc Input box to add width (auto) and TextAlign. The JUSTIFY properties, + * input long string of Numbers 1232312312318172312312312313121231231231231231232123123123 to check the effect + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0100', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances001 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances001") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances001 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0200 + * @tc.desc Input box to add width (auto) and TextAlign. The JUSTIFY properties, + * JLSDJFLJDLFJSLDFJLSDSFGSDFGSDFGSFGSGSDFGSFGSSFDGSDG long string input lowercase English letters, see the effect + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0200', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances002 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances002") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances002 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0300 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0300 + * @tc.desc Input box to add width (auto) and TextAlign. The JUSTIFY properties, + * long input string SDFJLSDJFLSJDFLJSDLFJSDLFJDSLJFSLDJFLSDJFLSDJFLSDJFSDFLJHS capital English letters, see the effect + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0300', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances003 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances003") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances003 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0400 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0400 + * @tc.desc Input box to add width (auto) and TextAlign. The JUSTIFY properties, + * enter a long string of mixed case jlsdjfljSDFLSJDFLJdlfFSDjFSFsldSDFSDFSDFgsSADFASDFdg English letters, see the effect + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0400', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances004 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances004") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances004 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0500 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0500 + * @tc.desc Add the width(auto) and TextAlign.JUSTIFY attributes to the input field, + * using long strings of Chinese characters mixed with Chinese and English characters. + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0500', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances005 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances005") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances005 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0600 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0600 + * @tc.desc Add the width(auto) and TextAlign.JUSTIFY attributes to the input field, + * using long strings of Chinese characters mixed with Chinese and English characters. + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0600', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances006 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances006") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances006 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0700 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0700 + * @tc.desc Add the width(auto) and TextAlign.JUSTIFY attributes to the input box, + * and a symbolic string to see the effect + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0700', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances007 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances007") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances007 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0800 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0800 + * @tc.desc Add the width(auto) and TextAlign.JUSTIFY properties, type the Enter key, and see how it works + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_0800', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances008 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances008") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances008 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_1000 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_1000 + * @tc.desc Add the width(auto) and TextAlign.JUSTIFY attributes to the input field, using single and double quotes to justify + */ + it('SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_1000', 0, async (done: Function) => { + Logger.info('TEST', `UIComponentTextTextareEnhances010 start.`); + Settings.createWindow("testability/pages/UIComponentTextTextareEnhances/UIComponentTextTextareEnhances010") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `UIComponentTextTextareEnhances010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_1100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_TEXTARE_ENHANCES_1100 + * @tc.desc Add the width(auto) and TextAlign.JUSTIFY attributes to the input box, + * and input the special characters "doucment.write("abc"),