Add "Wait for DOM inactivity" keyword which waits until page is fully loaded/rendered
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- javascript, python
- Lĩnh vực
- testing
Hướng nghiên cứu
Issue đề cập đến keyword mới Wait for DOM Inactivity của SeleniumLibrary và API Mutation Observer phía trình duyệt, nhưng không có file nào trong repository hoặc test nào. Hãy bắt đầu bằng cách xác định các entry point hiện có của các keyword chờ và các test của chúng; công việc được hoàn thành khi keyword này có thể dùng cho các trang động và hành vi của nó được các test bao phủ.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Prerequisites
- I have searched for similar issues in open tickets and cannot find a duplicate.
- The issue still exists against the latest released version of SeleniumLibrary.
- This is not a usage question or support request. For those, see more details in README.rst: https://github.com/robotframework/SeleniumLibrary#support
- You are not using the Java Selenium2Library: https://github.com/MarketSquare/robotframework-seleniumlibrary-java
- Remember that this is a public forum, so remember to remove all sensitive
information, like username and password.
For issues
Steps to reproduce the issue
N/A
Error messages and additional information
N/A
Expected behavior and actual behavior
N/A
Environment
N/A
Feature Request Background
In an effort to improve page performance, modern web apps load initial content, then load the rest of the data on the page via XHR requests. The page continues to mutate until all additional data is loaded. This is a major problem for old frameworks like Selenium, which simply wait until the initial page loads but do not wait until the content on the page fully loads.
Examples of this loading style can be found on sites like:
airbnb.com
amazon.com
buzzfeed.com
yahoo.com
A workaround we've found extremely useful at my company is to leverage the relatively new Mutation Observer api (docs here).
This mutation observer can be configured to fire a callback every time a node on the DOM is added or mutated. This can be used to detect when the page finally calms down and is ready for the automated test to continue.
Feature Request
My feature request, which I will implement, is to leverage this mutation observer in a new keyword "Wait for DOM Inactivity", which the user can call to wait on the XHR requests on dynamic pages (like those listed above) to finish.
Some key scenarios where this can be used are:
- pretty much any automated test which tests against a single page app
- whenever a button click opens & loads a modal
- on highly performant, dynamic pages which heavily leverage XHR requests (like those listed above)
Let me know if this interests you, I would be more than happy to implement this. I have used SeleniumLibrary extensively and love the library, and would love to contribute to it in any way.
Thank you for reading my request!
- Ngôn ngữ chính
- Python
- Star
- 1.5k
- Fork
- 787
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
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.
Issue khác của robotframework/SeleniumLibrary
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
robotframework/SeleniumLibrary#1941 · 3 bình luận ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 65/100
robotframework/SeleniumLibrary#1833 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
robotframework/SeleniumLibrary#1436 · 5 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 58/100
robotframework/SeleniumLibrary#1993 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
robotframework/SeleniumLibrary#1992 · 4 bình luận ·
Tất cả issue của robotframework/SeleniumLibrary
Issue tương tự
-
bug priority:low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
CyberAgent/psd2svg#436 ·
-
area/install-update comp/cli comp/desktop P3 sweeper:risk-compatibility type/bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
NousResearch/hermes-agent#122386 · 1 bình luận ·
-
ai-generated
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
vllm-project/production-stack#1105 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100