每次我在代码中运行测试时,都会收到此消息
org.testng.ITestNGListener: Provider io.qameta.allure.testng.AllureTestNg
could not be instantiated.
我对testNG有所了解,并且更新了诱惑力和testng的最新版本。
1.8.10
<build> <plugins> <plugin> <groupId> org.apache.maven.plugins </groupId> <artifactId> maven-surefire-plugin </artifactId> <version>2.20</version> <configuration> <suiteXmlFiles> <suiteXmlFile>testng.xml</suiteXmlFile> </suiteXmlFiles> <argLine> -javaagent:"${settings.localRepository}/org/aspectj/aspectjweaver/${aspectj.version}/aspectjweaver-${aspectj.version}.jar" </argLine> <groups/> </configuration> <dependencies> <dependency> <groupId>org.aspectj</groupId> <artifactId>aspectjweaver</artifactId> <version>${aspectj.version}</version> </dependency> </dependencies> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.6.2</version> <configuration> <source>1.8</source> <target>1.8</target> <encoding>UTF-8</encoding> </configuration> </plugin> </plugins> </build> <dependencies> <groupId>org.json</groupId> <artifactId>json</artifactId> <version>20080701</version> </dependency> <dependency> /* testng */ <groupId>org.testng</groupId> <artifactId>testng</artifactId> <version>6.13.1</version> </dependency> <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-simple</artifactId> <version>1.7.25</version> <scope>test</scope> </dependency> <dependency> /* allure testng */ <groupId>io.qameta.allure</groupId> <artifactId>allure-testng</artifactId> <version>2.6.0</version> </dependency> <dependency> <groupId>javax.xml.bind</groupId> <artifactId>jaxb-api</artifactId> <version>2.3.1</version> </dependency> </dependencies> </project>
我错过了一些依赖吗? 我想使用此工具创建报告,但只有该工具的安装卡住了。 我还根据一些程序员的建议添加了javax.xml.bind,但仍然无法正常工作。 顺便说一句,我打开了一个新的项目,魅力很好。
感谢您的帮助!
答案 0 :(得分:0)
尝试将诱惑测试的依赖性从2.6.0更改为2.7.0