getTestId method

String? getTestId({
  1. String key = defaultTestIdKey,
})

Gets the defaultTestIdKey prop value, or one testId from the prop (or custom key prop value).

For use in a testing environment (when testMode is true).

Implementation

String? getTestId({String key = defaultTestIdKey}) {
  return props[key] as String?;
}