[iOS] TestID for StatusBar component is not visible
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- C++
- Star
- 127k
- Fork
- 25.3k
- Merge trung bình
- 1 ngày 23 giờ
- Pull request đã merge (30 ngày)
- 4
Mô tả
Description
After adding testID, the new name attribute does not appear on the iOS platform, thanks to which I could use this element in my e2e tests. On the Android platform, this testID is visible as a resource-id attribute.
For example, in the Button component, after adding testID, the name attribute appears on the iOS platform, and for the Android platform, testID is visible as the resource-id attribute.
A screenshot from the Appium inspector tool, where all the attributes of the hidden element are visible (missing testID for iOS platform):
A screenshot from the Appium inspector tool, where all the attributes of the hidden element are visible (testID is visible as resource-id for the Android platform):
React Native Version
0.72.4
Output of npx react-native info
System:
OS: macOS 13.0.1
CPU: (8) arm64 Apple M1 Pro
Memory: 223.94 MB / 32.00 GB
Shell:
version: 5.8.1
path: /bin/zsh
Binaries:
Node:
version: 18.17.0
path: ~/.nvm/versions/node/v18.17.0/bin/node
Yarn:
version: 1.22.19
path: /usr/local/bin/yarn
npm:
version: 9.6.7
path: ~/.nvm/versions/node/v18.17.0/bin/npm
Watchman:
version: 2023.07.24.00
path: /opt/homebrew/bin/watchman
Managers:
CocoaPods:
version: 1.12.1
path: /Users/elzbietaszulc/.rvm/gems/ruby-2.7.6/bin/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 22.1
- iOS 16.1
- macOS 13.0
- tvOS 16.1
- watchOS 9.1
Android SDK: Not Found
IDEs:
Android Studio: 2021.3 AI-213.7172.25.2113.9123335
Xcode:
version: 14.1/14B47b
path: /usr/bin/xcodebuild
Languages:
Java:
version: 17.0.8
path: /usr/bin/javac
Ruby:
version: 2.7.6
path: /Users/elzbietaszulc/.rvm/rubies/ruby-2.7.6/bin/ruby
npmPackages:
"@react-native-community/cli": Not Found
react: Not Found
react-native: Not Found
react-native-macos: Not Found
npmGlobalPackages:
"react-native": Not Found
Android:
hermesEnabled: false
newArchEnabled: false
iOS:
hermesEnabled: true
newArchEnabled: false
Steps to reproduce
- Add testID="status_bar_hidden_button" to the StatusBarExample.js component (hidden element)
- Reload RNtester app
- Run the Appium Inspector tool
- Check if name attribute has been added for the iOS platform
Snack, screenshot, or link to a repository
A link to the StatusBar component that I defined:
A link to StatusBarExample.js where I added testID:
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với StatusBarExample.js và thay đổi liên quan đến component StatusBar, sau đó tái hiện trường hợp phần tử bị ẩn trong ứng dụng RNtester bằng Appium Inspector. So sánh các thuộc tính trợ năng của iOS với hành vi của resource-id trên Android; hoàn thành khi testID tạo ra thuộc tính name trên iOS như mong đợi cho phần tử StatusBar bị ẩn.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- ios, react-native
- Lĩnh vực
- mobile
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 45/100