Allow users to actually take advantage of passed categories via message regex.
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 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ệ
- python
- Lĩnh vực
- testing-qa
Hướng nghiên cứu
Bắt đầu với hook pytest_runtest_makereport trong adapter allure-pytest và truy vết cách report.longrepr hoặc longreprtext trở thành status_details. Bổ sung coverage cho một report đã passed có message khớp với messageRegex, và xác minh rằng categories.json có thể chọn category Passed được nêu tên.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
As a user of the categories.json, I want to be able to display "Passed" categories mapped from the categories.json using the messageRegex, so that I can show different "Passed" categories by Name in the UI.
I'm submitting a ...
- bug report
- feature request
- support request => Please do not submit support request here, see note at the top of this template.
What is the current behavior?
In pytest_runtest_makereport, the default value of status_details is None, and when test_result.status == Status.PASSED, it's still None.
As far as I know there's no way to actually provide a message that would enable this to work in a categories.json
[
{
"name": "Integration Passed",
"messageRegex": ".*IntegrationTest.*",
"matchedStatuses": ["passed"]
}
]
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
A simple bit of code I would expect to work
@pytest.hookimpl(hookwrapper=True)
def pytest_runtest_makereport(item, call):
report = (yield).get_result()
if call.when == "call" and report.passed:
report.longrepr = "IntegrationTest Passed"
What is the expected behavior?
That I can provide a Passed Message to allure to do stuff with the categories.json
status_details = StatusDetails(message=report.longreprtext)
Please tell us about your environment:
- Allure version: 2.26.0
- Test framework: [email protected]
- Allure adaptor: [email protected]
platform darwin -- Python 3.11.3, pytest-7.4.2, pluggy-1.3.0
plugins: cov-4.1.0, mock-3.11.1, anyio-3.7.1, xdist-3.3.1, check-2.2.2, allure-pytest-2.13.2
Other information
None
- Ngôn ngữ chính
- Python
- Star
- 820
- Fork
- 262
- Merge trung bình
- 3 giờ 20 phút
- Pull request đã merge (30 ngày)
- 3
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc 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 allure-framework/allure-python
-
[allure-behave] Steps from tag-excluded scenarios bleed into the next matching scenario's result when hide_excluded=trueCó thể đã có người làm @liuyaohui666 đã nhận 56 ngày trước. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 84/100
-
theme:pytest
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 64/100
allure-framework/allure-python#929 · 1 reaction ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 30/100
allure-framework/allure-python#930 · 3 bình luận ·
-
Added CategoriesĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
-
Phantom <lambda> teardown entries with unknown status when using pytest 9.1+Có thể đã có người làm @Mohanad49 đã nhận 61 ngày trước. Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 58/100
allure-framework/allure-python#918 · 2 reaction ·
Tất cả issue của allure-framework/allure-python
Issue tương tự
-
bot-triaged module: LrScheduler module: optimizer triaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
Maintainer thường phản hồi trong vòng 1 ngày
-
documentation glm5 llm-model
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
vllm-project/vllm-ascend#19062 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Author Page: shuai-zhao-llmĐang mởauthor-page correction
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
acl-org/acl-anthology#10496 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Issue Type: Bug Report
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
celery/celery#10875 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
SasanLabs/VulnerableApp#836 ·
Maintainer thường phản hồi trong vòng 1 ngày