Skip to content

Commit 41d4917

Browse files
authored
Add Slider testID (#999)
1 parent b2296a0 commit 41d4917

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/components/slider/index.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,8 @@ export default class Slider extends PureBaseComponent {
9696
/**
9797
* If true the Slider will be disabled and will appear in disabled color
9898
*/
99-
disabled: PropTypes.bool
99+
disabled: PropTypes.bool,
100+
testID: PropTypes.string
100101
};
101102

102103
static defaultProps = {
@@ -479,7 +480,8 @@ export default class Slider extends PureBaseComponent {
479480
renderTrack,
480481
disabled,
481482
minimumTrackTintColor = ACTIVE_COLOR,
482-
maximumTrackTintColor = DEFAULT_COLOR
483+
maximumTrackTintColor = DEFAULT_COLOR,
484+
testID
483485
} = this.getThemeProps();
484486

485487
return (
@@ -494,6 +496,7 @@ export default class Slider extends PureBaseComponent {
494496
// accessibilityActions={['increment', 'decrement']}
495497
accessibilityActions={[{name: 'increment', label: 'increment'}, {name: 'decrement', label: 'decrement'}]}
496498
onAccessibilityAction={this.onAccessibilityAction}
499+
testID={testID}
497500
>
498501
{_.isFunction(renderTrack) ? (
499502
<View

0 commit comments

Comments
 (0)