pytest+allure报告层级

@allure.epic("测试项目")
@allure.feature("测试模块")
@allure.story("测试添加、删除、修改")
class TestDemo:
    @allure.title("测试用例001")
    @allure.description("这是用例描述")
    def test001(self):
        with allure.step("步骤:第一步"):
            assert 1 == 2

    @allure.title("测试用例002")
    @allure.step("步骤:第二步")
    def test002(self):
        assert 2 == 2

 报告显示如下:

 

posted @ 2022-06-27 15:08  LeeV1  阅读(203)  评论(0)    收藏  举报