diff --git a/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/TestAbility/pages/IndexSec.ets b/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/TestAbility/pages/IndexSec.ets index 4689ab1f2f96c3315ac4f385c6f4f03a6b231b9f..83ea66663a7b76881f7759d5c5d18d23d79db86d 100644 --- a/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/TestAbility/pages/IndexSec.ets +++ b/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/TestAbility/pages/IndexSec.ets @@ -172,6 +172,10 @@ struct TabsExampleSec { .barBackgroundColor(this.barBackgroundColorString) .key('BarBackgroundColorString') + Button("ResourceColor") + .fontSize(40) + .backgroundColor($r("sys.color.ohos_toggle_bg")) + .key("ResourceColor") Tabs({ barPosition: BarPosition.End, controller: this.controller }) { TabContent() { Column(){ diff --git a/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/test/TabsSec.ets b/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/test/TabsSec.ets index 7c1341d26a8807083d816b5a296b55f33d98f98b..7212a711d16e3d51fd4bf04307c31a9e68a4865b 100644 --- a/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/test/TabsSec.ets +++ b/arkui/ace_ets_components_ux/ace_ets_component_tabs/src/main/ets/test/TabsSec.ets @@ -526,7 +526,10 @@ export default function tabsSec() { let obj = JSON.parse(newJson); console.info("[ArkUI_Tabs_BarBackgroundColor_0500] barBackgroundColor:" + JSON.stringify(obj.$attrs.barBackgroundColor)); let barBackgroundColorObject = obj.$attrs.barBackgroundColor; - expect(barBackgroundColorObject).assertEqual("#0C182431"); + let newColor = getInspectorByKey('ResourceColor'); + let objColor = JSON.parse(newColor); + console.info("[ArkUI_Tabs_BarBackgroundColor_0500] objColor:" + JSON.stringify(objColor.$attrs.backgroundColor)); + expect(barBackgroundColorObject).assertEqual(objColor.$attrs.backgroundColor); done(); });