Skip to content

chore(test): add test-tabs-item-icon appearance scenario#4108

Open
LKuchno wants to merge 5 commits into
mainfrom
@lkuchno/test-tabs-item-icon
Open

chore(test): add test-tabs-item-icon appearance scenario#4108
LKuchno wants to merge 5 commits into
mainfrom
@lkuchno/test-tabs-item-icon

Conversation

@LKuchno
Copy link
Copy Markdown
Collaborator

@LKuchno LKuchno commented May 29, 2026

Description

Adds a new manual test scenario (test-tabs-item-icon) that exercises the iOS and Android tab bar item icon color props exposed on TabsScreen.
For iOS: the scenario covers four distinct icon configuration cases: templateSource (tintable, check with host tint), sfSymbol with tabBarItemIconColor override, xcasset (tintable, check with host tint), and imageSource (non-tintable). It verifies that standardAppearance.stacked.selected.tabBarItemIconColor correctly overrides the host-level tabBarTintColor for the selected icon color, and that imageSource icons are non-tintable and unaffected by either prop.

For Android, the scenario covers two distinct icon configuration cases: drawableResource and imageSource. It verifies icon changes for both selected and unselected tabs, as well as tabBarItemIconColor rendering for the icon in normal, selected, and focused states.

Automated Detox assertions are not feasible because Detox does not expose tint color or rendered image attributes of native tab bar items. Known behavioral differences between iOS 18 and iOS 26 are documented in the scenario notes.

Closes: https://github.com/software-mansion/react-native-screens-labs/issues/1399

Closes: https://github.com/software-mansion/react-native-screens-labs/issues/1404

Changes

  • Tests/Tabs: Added test-tabs-item-icon/index.tsx - new test screen with for iOS: four tab routes exercising templateSource host-tint, sfSymbol with tabBarItemIconColor override, xcasset host-tint, and non-tintable imageSource icon; for Android: two tab routes exercising drawableResource and imageSource with ' tabBarItemIconColor` rendering for icon in normal, selected and focused states.
  • Tests/Tabs: Added scenario-description.ts
  • Tests/Tabs: Added scenario.md with full manual test steps - separate for each OS type. iOS 18 vs iOS 26 known-issue callouts, and per-step verification checklists
  • Tests/Tabs: Registered TestTabsItemIcon in apps/src/tests/single-feature-tests/tabs/index.ts

Test visual documentation

Screen.Recording.2026-05-29.at.11.41.33.mov

@LKuchno LKuchno added area:tabs Issue related to bottom tabs type:chore A general maintenance task, that does not fall into other categories. labels May 29, 2026
@LKuchno LKuchno requested a review from Copilot May 29, 2026 08:02
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new manual test scenario (test-tabs-item-icon) under the Tabs single-feature tests to visually validate TabsScreen tab bar item icon configuration and tinting behaviors on iOS and Android.

Changes:

  • Added a new scenario screen with platform-specific tab routes covering templateSource, sfSymbol, xcasset, drawableResource, and imageSource.
  • Added scenario metadata (scenario-description.ts) and a detailed manual test script (scenario.md).
  • Registered the scenario in the Tabs scenario group.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.

File Description
apps/src/tests/single-feature-tests/tabs/test-tabs-item-icon/index.tsx Implements the new Tabs icon scenario screen and route configs for iOS/Android.
apps/src/tests/single-feature-tests/tabs/test-tabs-item-icon/scenario-description.ts Declares the scenario’s metadata (name/key/details/platforms).
apps/src/tests/single-feature-tests/tabs/test-tabs-item-icon/scenario.md Provides manual verification steps and expected results for iOS/Android.
apps/src/tests/single-feature-tests/tabs/index.ts Registers the new scenario in the Tabs scenario list.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +156 to +160
- [ ] Expected: Each tab swaps between its `icon` and `selectedIcon`
(where configured) consistently on selection. The correct tint
behavior is applied each time: green host tint for **Tint** and
**Xcasset**, red override for **Override**'s selected state, and
no tint effect for **Image**. No crash, layout freeze, or visual
Comment on lines +102 to +107
- [ ] Expected: The icon swaps from the outline image to
the filled image. Both renders use the original PNG
colors - the host `tabBarTintColor` (green) have NO effect on the
selected icon. On iOS 18, the unselected icon renders in
**blue**; on iOS 26+ it renders in the system theme
color.
Comment on lines +73 to +75
On iOS 18 the selected title is
green (host tint); on iOS 26 the selected title is red (override - it's native
bug KI linked in Notes section).
Comment thread apps/src/tests/single-feature-tests/tabs/test-tabs-item-icon/index.tsx Outdated
@LKuchno LKuchno changed the title chore(test): add tab-item-icon appearance scenario chore(test): add test-tabs-item-icon appearance scenario May 29, 2026
LKuchno and others added 2 commits May 29, 2026 12:44
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@LKuchno LKuchno requested a review from kkafar May 29, 2026 11:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:tabs Issue related to bottom tabs type:chore A general maintenance task, that does not fall into other categories.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants