allure-framework / allure-framework/allure-python
using pytest.mark.parametrize will miss some testcase in report
- 主要言語
- Python
- スター
- 814
- フォーク
- 260
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
#### I'm submitting a ...
- [x] 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?
when i use `pytest.mark.parametrize` ,in specific data situations, i got same historyId for two diffent testcase, when report cameout, only one of two testcase show in report.
#### If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
Code to repeat :
```python
data = [
["", "admin", 12345],
["admin", "", 12345],
]
@pytest.mark.parametrize("name, account, phone_number", data)
def test_add_member(name, account, phone_number):
print(name, account, phone_number)
```
#### What is the expected behavior?
expected got 2 testcase in report
#### What is the motivation / use case for changing the behavior?
#### Please tell us about your environment:
- Allure version: 2.19.0
- Test framework: pytest@7.2.2
- Allure adaptor: allure-pytest@2.13.2
#### Other information
Becourse in `allure_pytest.util.get_history_id`, only use values in original_values to generate historyId
Maybe use both name and value will solve the problem
コントリビューションガイド
調査の方向性
allure_pytest.util.get_history_id から始め、レポートに示されている2つのパラメータ化されたテストケースで問題を再現します。original_values が historyId の生成にどのように使用されているかを確認します。両方の異なるテストケースが、個別の history IDs とともに Allure report に表示されれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- testing
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 52/100