当前位置: 首页 > 知识库问答 >
问题:

无法生成诱惑报告

方茂
2023-03-14
<target name="run" depends="compile, gendoc" description="Execute Selenium Tests">
        <testng classpath="${test.classpath}:${test.dest}" suitename="Selenium_Tests" outputdir="${test.report}" workingdir="${test.report}"
                useDefaultListeners="true"
                listeners="org.uncommons.reportng.HTMLReporter,
                           org.uncommons.reportng.JUnitXMLReporter">
            <jvmarg value="-javaagent:${ivy.lib.dir}/aspectjweaver-${aspectj.version}.jar"/>
            <xmlfileset dir="." includes="testng.xml"/>
        </testng>
        <copy todir="${test.report-dir}">
            <fileset dir="${test.report}"/>
        </copy></target>

上面的代码用于生成allure报告并运行测试,它运行并生成reports-allure-results中的一个文件夹,其中包含JSON文件。见下方截图

共有1个答案

景建业
2023-03-14

步骤1.在pom.xml https://mvnrepository.com/artifact/ru.yandex.qatools.Allure/allure-report-builder/2.1中添加dependencies Allure Builder Reporter

第二步:添加下面的代码。

// It will generate the Allure Report folder.
new AllureReportBuilder("1.5.4", new File("target/allure-report")).unpackFace(); 
new AllureReportBuilder("1.5.4", new File("target/allure-report")).processResults(new File("target/allure-results"));
 类似资料:
  • 7.1.0 MVN测试命令应该正常执行测试,知道同样的POM在我更新testNG和其他一些依赖之前工作正常,我也在testNG和maven中使用诱惑力,现在如果我禁用诱惑力-TestNG测试将被执行,但诱惑力不会生成任何报告 我收到此错误。有关单个测试结果,请参阅C:\Users\warrior\Desktop\MobileAutomationTest\target\surefire报告。请参阅转

  • 我无法使用allure-maven插件生成AllureTestHTML报告。我使用的是相同版本的testNG-adapter和allure maven插件(1.4.0.rc8)。但是我能够使用allure CLI生成allure html报告。排除依赖项的pom.xml是

  • 你能帮我做以下几件事吗? 进行量角器测试。

  • 我使用“selenide”、“testng”、“maven”、“eclipse”创建了一些自动化脚本。我试着添加诱惑力测试结果。我遵循了allure-testng-maven说明并更新了pom.xml。 要从eclipse运行测试,我要右键单击pom.xml+“run as”+“Maven test”。这是在“./target/allure-results”文件夹中执行所有testng测试和生成的

  • 我已经成功地将Allure报表集成到我基于maven的testNG项目中,并能够使用jetty服务器查看报表。但是现在我正试图按照这里建议的指示来整合诱惑报告和詹金斯-http://wiki.qatools.ru/display/al/allure+jenkins+plugin我现在能够在我的詹金斯页面上看到诱惑图标,但是如果我点击这个图标,我会看到一个404-“页面找不到”错误。