allure-framework / allure-framework/allure-python

Prevent allure from force adding test folder name as parent suite name when parent suite is not specified

オープン
#903 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Python
スター
814
フォーク
260
PR マージ指標
30日以内にマージされた PR はありません

説明

I have tests in several folders with all tests having a common **allure.dynamic.suite** name.
In my allure report all the tests get grouped under this name.

However, of late, the suites go under the folder name of the tests such that the folder name is taken as the Parent Suite.

Is there a way to prevent the folder names from being taken as Parent Suite name and simply group the tests under the suite names like how it used to be?

The only way i can think of currently to avoid this issue is to rename all allure.dynamic.suite to allure.dynamic.parent_suite in all of my tests.

But the reason this will be a problem is,
If I collect multiple allure artifacts and consolidate them into a single report, I would want to group them under a common parent suite name. But since each report will have a parent suite name, they will get overwritten.

### What Operating System are you using (both controller, and any agents involved in the problem)?

Windows

### Reproduction steps

1. Have tests in two folders (Folder_A, Folder_B) with each of the tests having the same allure.dynamic.suite name("Tests")
2. Run the tests and generate allure report

### Expected Results

Report should display,

Image

### Actual Results

Report is displaying,

Image

The name of the test folder is taken as the parent suite name although no parent suite has been specified.

### Anything else?
Can we have,
A configuration option like `--no-parent-suite` or `--disable-auto-parent-suite`
Or a new pytest.ini option like `allure_skip_parent_suite = true`

### Are you interested in contributing a fix?

Yes

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

同じ allure.dynamic.suite("Tests") の値を共有する Folder_A と Folder_B のテストでレポートを再現する。親スイートを割り当てる pytest の統合パスと、issue で言及されている pytest.ini の設定を調査する。明示的に指定されていない場合にフォルダー名が親スイートとして追加されず、明示的に定義された親スイートは引き続き機能すれば完了とする。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
testing
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
静か
明瞭さ
おおむね明確
初心者へのやさしさ
45/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。