diff --git a/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/TestAbility/pages/Index.ets b/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/TestAbility/pages/Index.ets index 4ad4fdfcb8abcb02920bdaba348bbb949bc40a18..2f1e2a30c74e76be497328d4824618e8e9ec7505 100644 --- a/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/TestAbility/pages/Index.ets +++ b/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/TestAbility/pages/Index.ets @@ -549,6 +549,164 @@ struct DatapanelTest { .trackShadow({ offsetY: null }) .key("ArkUX_Stage_DataPanel_TrackShadow_1400") } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ offsetY: undefined }) + .key("ArkUX_Stage_DataPanel_TrackShadow_1500") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: this.color20 }) + .key("ArkUX_Stage_DataPanel_TrackShadow_1600") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: this.color21 }) + .key("ArkUX_Stage_DataPanel_TrackShadow_1700") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: this.color22 }) + .key("ArkUX_Stage_DataPanel_TrackShadow_1800") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: [$r("app.color.DataPanel_TrackShadow1"), $r("app.color.DataPanel_TrackShadow2"), + $r("app.color.DataPanel_TrackShadow3")] }) + .key("ArkUX_Stage_DataPanel_TrackShadow_1900") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: '' }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2000") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: null }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2100") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: undefined }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2200") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: [this.color23, this.color24, this.color25] }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2300") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: [this.color26, this.color27, this.color28] }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2400") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: [this.color29, this.color30, this.color31]}) + .key("ArkUX_Stage_DataPanel_TrackShadow_2500") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: [$r("app.color.DataPanel_TrackShadow4"), $r("app.color.DataPanel_TrackShadow5"), + $r("app.color.DataPanel_TrackShadow6"), $r("app.color.DataPanel_TrackShadow7"), + $r("app.color.DataPanel_TrackShadow8"), $r("app.color.DataPanel_TrackShadow9")]}) + .key("ArkUX_Stage_DataPanel_TrackShadow_2600") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: '' }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2700") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: null }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2800") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: undefined }) + .key("ArkUX_Stage_DataPanel_TrackShadow_2900") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: this.colorArray1 }) + .key("ArkUX_Stage_DataPanel_TrackShadow_3000") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: this.colorArray2 }) + .key("ArkUX_Stage_DataPanel_TrackShadow_3100") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: this.colorArray3 }) + .key("ArkUX_Stage_DataPanel_TrackShadow_3200") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: [$r("app.color.DataPanel_TrackShadow10"), $r("app.color.DataPanel_TrackShadow11"), + $r("app.color.DataPanel_TrackShadow12")]}) + .key("ArkUX_Stage_DataPanel_TrackShadow_3300") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: '' }) + .key("ArkUX_Stage_DataPanel_TrackShadow_3400") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: null }) + .key("ArkUX_Stage_DataPanel_TrackShadow_3500") + } + ListItem() { + DataPanel({ values: [20, 10, 10], max: 80, type: DataPanelType.Circle }) + .width(200) + .height(200) + .trackShadow({ colors: undefined }) + .key("ArkUX_Stage_DataPanel_TrackShadow_3600") + } } } .width('100%') diff --git a/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/test/datapanel.ets b/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/test/datapanel.ets index 5133711327b4511a369f0bf988c3a0bc80390be5..7be45e5645b569b19002e30e1e8fb717064d750d 100644 --- a/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/test/datapanel.ets +++ b/arkui/ace_ets_components_ux/ace_ets_component_datapanel/src/main/ets/test/datapanel.ets @@ -2262,5 +2262,1110 @@ export default function datapanelTest() { } }, 500) }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_1500 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.offsetY : undefined + */ + it('ArkUX_Stage_DataPanel_TrackShadow_1500', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_1500 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_1500'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1500 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1500 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1500 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1500 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.offsetY).assertEqual("5.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1500 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1500 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_1600 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * ["#FFFF0000", "#FFFFFF00", "#FF00FF00"] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_1600', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_1600 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_1600'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1600 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1600 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1600 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1600 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1600 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1600 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_1700 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * ['rgb(255,0,0)', 'rgb(255,255,0)', 'rgb(0,255,0)'] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_1700', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_1700 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_1700'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1700 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1700 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1700 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1700 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1700 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1700 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_1800 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [Color.Red, Color.Yellow, Color.Green] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_1800', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_1800 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_1800'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1800 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1800 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1800 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1800 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FF008000"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FF008000"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1800 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1800 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_1900 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [$r("app.color.DataPanel_TrackShadow1"),$r("app.color.DataPanel_TrackShadow2"), + * $r("app.color.DataPanel_TrackShadow3")] } + */ + it('ArkUX_Stage_DataPanel_TrackShadow_1900', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_1900 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_1900'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1900 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_1900 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1900 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_1900 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1900 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_1900 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2000 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors : '' + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2000', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2000 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2000'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2000 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_2000 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2000 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2000 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2000 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2000 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2100 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors : null + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2100', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2100 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2100'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2100 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_2100 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2100 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2100 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2100 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2100 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2200 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors : undefined + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2200', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2200 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2200'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2200 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_2200 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2200 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2200 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2200 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2200 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2300 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [{ color: "#FFA500", offset: 0 }, { color: "#FFFFFF00", offset: 1 }], + * [{ color: "#FFC0CB", offset: 0 }, { color: "#FF00FF00", offset: 1 }], + * [{ color: "#FF0000FF", offset: 0 }, { color: "#FFFF0000", offset: 1 }] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2300', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2300 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2300'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2300 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2300 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2300 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2300 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2300 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2300 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2400 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [{ color: 'rgb(255,165,0)', offset: 0 }, { color: 'rgb(255,255,0)', offset: 1 }] + * [{ color: 'rgb(255,192,203)', offset: 0 }, { color: 'rgb(0,128,0)', offset: 1 }] + * [{ color: 'rgb(0,0,255)', offset: 0 }, { color: 'rgb(255,0,0)', offset: 1 }] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2400', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2400 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2400'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2400 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2400 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2400 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2400 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FF008000"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2400 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2400 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2500 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [{ color: Color.Orange, offset: 0 }, { color: Color.Yellow, offset: 1 }] + * [{ color: Color.Pink, offset: 0 }, { color: Color.Green, offset: 1 }] + * [{ color: Color.Blue, offset: 0 }, { color: Color.Red, offset: 1 }] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2500', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2500 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2500'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2500 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2500 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2500 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2500 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FF008000"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2500 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2500 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2600 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [$r("app.color.DataPanel_TrackShadow4"), $r("app.color.DataPanel_TrackShadow5"), + * $r("app.color.DataPanel_TrackShadow6"), $r("app.color.DataPanel_TrackShadow7"), + * $r("app.color.DataPanel_TrackShadow8"), $r("app.color.DataPanel_TrackShadow9")] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2600', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2600 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2600'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2600 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2600 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2600 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2600 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFFF00"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2600 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2600 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2700 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors : '' + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2700', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2700 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2700'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2700 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_2700 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2700 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2700 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2700 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2700 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2800 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors : null + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2800', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2800 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2800'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2800 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_2800 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2800 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2800 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2800 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2800 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_2800 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors : undefined + */ + it('ArkUX_Stage_DataPanel_TrackShadow_2900', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_2900 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_2900'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2900 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_2900 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2900 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_2900 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2900 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_2900 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3000 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * ["#FF0000FF", [{ color: "#FFA500", offset: 0 }, { color: "#FFC0CB", offset: 1 }]] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3000', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3000 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3000'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3000 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3000 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3000 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3000 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FF0000FF"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3000 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3000 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3100 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * ['rgb(255,0,0)', [{ color: 'rgb(255,165,0)', offset: 0 }, { color: 'rgb(255,192,203)', offset: 1}]] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3100', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3100 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3100'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3100 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3100 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3100 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3100 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3100 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3100 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3200 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [Color.Red, [{ color: Color.Orange, offset: 0 }, { color: Color.Pink, offset: 1 }]] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3200', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3200 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3200'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3200 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3200 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3200 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3200 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFFFA500"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3200 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3200 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3300 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: + * [$r("app.color.DataPanel_TrackShadow10"), $r("app.color.DataPanel_TrackShadow11"), + * $r("app.color.DataPanel_TrackShadow12")] + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3300', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3300 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3300'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3300 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3300 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3300 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3300 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFFFC0CB"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FF00FF00"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFFF0000"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3300 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3300 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3400 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: '' + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3400', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3400 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3400'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3400 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_3400 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3400 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3400 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3400 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3400 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3500 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: null + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3500', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3500 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3500'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3500 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_3500 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3500 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3500 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3500 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3500 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); + + /** + * @tc.number ArkUX_Stage_DataPanel_TrackShadow_3600 + * @tc.name Tests the trackShadow property of the DataPanel component + * @tc.desc DataPanel common components, set trackShadow property parameter to trackShadow.colors: undefined + */ + it('ArkUX_Stage_DataPanel_TrackShadow_3600', 0, async function (done) { + console.info('ArkUX_Stage_DataPanel_TrackShadow_3600 START'); + setTimeout(() => { + try { + let strJson = getInspectorByKey('ArkUX_Stage_DataPanel_TrackShadow_3600'); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3600 strJson :' + JSON.stringify(strJson)); + let obj = JSON.parse(strJson); + let trackShadow = obj.$attrs.trackShadow; + console.info("ArkUX_Stage_DataPanel_TrackShadow_3600 component obj is: " + JSON.stringify(obj)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3600 component obj.$attrs is: " + + JSON.stringify(obj.$attrs)); + console.info("ArkUX_Stage_DataPanel_TrackShadow_3600 component obj.$attrs.trackShadow is: " + + JSON.stringify(obj.$attrs.trackShadow)); + hilog.info(0x0000, 'testTag', '%{public}s', JSON.stringify(obj.$attrs.trackShadow.colors)); + expect(obj.$attrs.trackShadow.colors[0][0].color).assertEqual("#FFF7CE00"); + expect(obj.$attrs.trackShadow.colors[0][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[0][1].color).assertEqual("#FFF99B11"); + expect(obj.$attrs.trackShadow.colors[0][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[1][0].color).assertEqual("#FFF76223"); + expect(obj.$attrs.trackShadow.colors[1][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[1][1].color).assertEqual("#FFF2400A"); + expect(obj.$attrs.trackShadow.colors[1][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[2][0].color).assertEqual("#FFF772AC"); + expect(obj.$attrs.trackShadow.colors[2][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[2][1].color).assertEqual("#FFE65392"); + expect(obj.$attrs.trackShadow.colors[2][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[3][0].color).assertEqual("#FFA575EB"); + expect(obj.$attrs.trackShadow.colors[3][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[3][1].color).assertEqual("#FFA12DF7"); + expect(obj.$attrs.trackShadow.colors[3][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[4][0].color).assertEqual("#FF7B79F7"); + expect(obj.$attrs.trackShadow.colors[4][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[4][1].color).assertEqual("#FF4B48F7"); + expect(obj.$attrs.trackShadow.colors[4][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[5][0].color).assertEqual("#FF4B8AF3"); + expect(obj.$attrs.trackShadow.colors[5][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[5][1].color).assertEqual("#FF007DFF"); + expect(obj.$attrs.trackShadow.colors[5][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[6][0].color).assertEqual("#FF73C1E6"); + expect(obj.$attrs.trackShadow.colors[6][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[6][1].color).assertEqual("#FF4FB4E3"); + expect(obj.$attrs.trackShadow.colors[6][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[7][0].color).assertEqual("#FFA5D61D"); + expect(obj.$attrs.trackShadow.colors[7][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[7][1].color).assertEqual("#FF69D14F"); + expect(obj.$attrs.trackShadow.colors[7][1].offset).assertEqual("1.000000"); + expect(obj.$attrs.trackShadow.colors[8][0].color).assertEqual("#FFA2A2B0"); + expect(obj.$attrs.trackShadow.colors[8][0].offset).assertEqual("0.000000"); + expect(obj.$attrs.trackShadow.colors[8][1].color).assertEqual("#FF8E8E93"); + expect(obj.$attrs.trackShadow.colors[8][1].offset).assertEqual("1.000000"); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3600 END '); + done(); + } catch (err) { + expect().assertFail(); + console.info('ArkUX_Stage_DataPanel_TrackShadow_3600 ERR ' + JSON.stringify(err)); + done(); + } + }, 500) + }); }) } \ No newline at end of file