Skip to content

Add missing Fantom integration test coverage for TouchableHighlight#55928

Closed
ellemac123 wants to merge 1 commit intofacebook:mainfrom
ellemac123:export-D95225416
Closed

Add missing Fantom integration test coverage for TouchableHighlight#55928
ellemac123 wants to merge 1 commit intofacebook:mainfrom
ellemac123:export-D95225416

Conversation

@ellemac123
Copy link
Copy Markdown

Summary:
Changelog: [Internal]

Add tests for previously untested TouchableHighlight-specific features
in the Fantom integration test suite:

  • underlayColor: Verify default underlay color ('black') and custom
    underlay color ('red') render correctly when pressed, using
    testOnly_pressed={true} to force the pressed visual state.

  • activeOpacity (pressed state): Verify default activeOpacity (0.85)
    and custom activeOpacity (0.5) are applied to the child element's
    opacity when pressed.

  • onShowUnderlay: Verify the callback fires when the element is
    clicked, via Fantom.dispatchNativeEvent.

  • displayName: Verify TouchableHighlight.displayName is
    'TouchableHighlight'.

These tests cover the underlay mechanism, which is the defining feature
of TouchableHighlight that distinguishes it from TouchableOpacity.

Reviewed By: NickGerleman

Differential Revision: D95225416

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Mar 5, 2026
@meta-codesync
Copy link
Copy Markdown

meta-codesync bot commented Mar 5, 2026

@ellemac123 has exported this pull request. If you are a Meta employee, you can view the originating Diff in D95225416.

ellemac123 pushed a commit to ellemac123/react-native that referenced this pull request Mar 5, 2026
…acebook#55928)

Summary:

Changelog: [Internal]

Add tests for previously untested TouchableHighlight-specific features
in the Fantom integration test suite:

- **underlayColor**: Verify default underlay color ('black') and custom
  underlay color ('red') render correctly when pressed, using
  `testOnly_pressed={true}` to force the pressed visual state.

- **activeOpacity (pressed state)**: Verify default activeOpacity (0.85)
  and custom activeOpacity (0.5) are applied to the child element's
  opacity when pressed.

- **onShowUnderlay**: Verify the callback fires when the element is
  clicked, via `Fantom.dispatchNativeEvent`.

- **displayName**: Verify `TouchableHighlight.displayName` is
  `'TouchableHighlight'`.

These tests cover the underlay mechanism, which is the defining feature
of TouchableHighlight that distinguishes it from TouchableOpacity.

Reviewed By: NickGerleman

Differential Revision: D95225416
ellemac123 pushed a commit to ellemac123/react-native that referenced this pull request Mar 5, 2026
…acebook#55928)

Summary:
Pull Request resolved: facebook#55928

Changelog: [Internal]

Add tests for previously untested TouchableHighlight-specific features
in the Fantom integration test suite:

- **underlayColor**: Verify default underlay color ('black') and custom
  underlay color ('red') render correctly when pressed, using
  `testOnly_pressed={true}` to force the pressed visual state.

- **activeOpacity (pressed state)**: Verify default activeOpacity (0.85)
  and custom activeOpacity (0.5) are applied to the child element's
  opacity when pressed.

- **onShowUnderlay**: Verify the callback fires when the element is
  clicked, via `Fantom.dispatchNativeEvent`.

- **displayName**: Verify `TouchableHighlight.displayName` is
  `'TouchableHighlight'`.

These tests cover the underlay mechanism, which is the defining feature
of TouchableHighlight that distinguishes it from TouchableOpacity.

Reviewed By: NickGerleman

Differential Revision: D95225416
…acebook#55928)

Summary:

Changelog: [Internal]

Add tests for previously untested TouchableHighlight-specific features
in the Fantom integration test suite:

- **underlayColor**: Verify default underlay color ('black') and custom
  underlay color ('red') render correctly when pressed, using
  `testOnly_pressed={true}` to force the pressed visual state.

- **activeOpacity (pressed state)**: Verify default activeOpacity (0.85)
  and custom activeOpacity (0.5) are applied to the child element's
  opacity when pressed.

- **onShowUnderlay**: Verify the callback fires when the element is
  clicked, via `Fantom.dispatchNativeEvent`.

- **displayName**: Verify `TouchableHighlight.displayName` is
  `'TouchableHighlight'`.

These tests cover the underlay mechanism, which is the defining feature
of TouchableHighlight that distinguishes it from TouchableOpacity.

Reviewed By: NickGerleman

Differential Revision: D95225416
@meta-codesync meta-codesync bot closed this in 6d4fcbf Mar 5, 2026
@facebook-github-bot facebook-github-bot added the Merged This PR has been merged. label Mar 5, 2026
@meta-codesync
Copy link
Copy Markdown

meta-codesync bot commented Mar 5, 2026

This pull request has been merged in 6d4fcbf.

@react-native-bot
Copy link
Copy Markdown
Collaborator

This pull request was successfully merged by Laura Macaluso in 6d4fcbf

When will my fix make it into a release? | How to file a pick request?

zoontek pushed a commit to zoontek/react-native that referenced this pull request Mar 9, 2026
…acebook#55928)

Summary:
Pull Request resolved: facebook#55928

Changelog: [Internal]

Add tests for previously untested TouchableHighlight-specific features
in the Fantom integration test suite:

- **underlayColor**: Verify default underlay color ('black') and custom
  underlay color ('red') render correctly when pressed, using
  `testOnly_pressed={true}` to force the pressed visual state.

- **activeOpacity (pressed state)**: Verify default activeOpacity (0.85)
  and custom activeOpacity (0.5) are applied to the child element's
  opacity when pressed.

- **onShowUnderlay**: Verify the callback fires when the element is
  clicked, via `Fantom.dispatchNativeEvent`.

- **displayName**: Verify `TouchableHighlight.displayName` is
  `'TouchableHighlight'`.

These tests cover the underlay mechanism, which is the defining feature
of TouchableHighlight that distinguishes it from TouchableOpacity.

Reviewed By: NickGerleman

Differential Revision: D95225416

fbshipit-source-id: d1923c27d1ec9536d6b1e4ae41ba750212f27bc6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. meta-exported p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants