mvn 用reportng美化输出

<pre name="code" class="html"><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<groupId>sele</groupId>
	<artifactId>sele</artifactId>
	<version>0.0.1-SNAPSHOT</version>
	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
	</properties>
	
	<dependencies>
		<dependency>
			<groupId>org.testng</groupId>
			<artifactId>testng</artifactId>
			<version>6.9.9</version>   
		</dependency> 
		
		<dependency>
			<groupId>org.seleniumhq.selenium</groupId>
			<artifactId>selenium-java</artifactId>
			<version>2.50.1</version>
		</dependency>

		<dependency>
		    <groupId>com.google.inject</groupId>
		    <artifactId>guice</artifactId>
		    <version>4.1.0</version>
		</dependency>		
		
		<dependency>
	        <groupId>org.uncommons</groupId>
	        <artifactId>reportng</artifactId>
	        <version>1.1.4</version>
	        <scope>test</scope>
	        <exclusions>
	            <exclusion>
	                <groupId>org.testng</groupId>
	                <artifactId>testng</artifactId>
	            </exclusion>
	        </exclusions>
	    </dependency>								
  	</dependencies>	
  	
		
	<build>
	    <sourceDirectory>src</sourceDirectory>
		<plugins>
			<plugin>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.5.1</version>
				<configuration>
				  <source>1.7</source>
				  <target>1.7</target>
				</configuration>
			</plugin>
			
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.19.1</version>
				<executions>
					<execution>
						<configuration>
							<suiteXmlFiles>
								<suiteXmlFile>testng.xml</suiteXmlFile>
							</suiteXmlFiles>
						</configuration>
					</execution>
				</executions>			
				<configuration>
	                <properties>
	                    <property>
	                        <name>usedefaultlisteners</name>
	                        <value>false</value>
	                    </property>
	                    <property>
	                        <name>listener</name>                      
	                        <value>org.uncommons.reportng.HTMLReporter,  org.uncommons.reportng.JUnitXMLReporter</value>
	                    </property>
	                </properties>
	                <workingDirectory>target/</workingDirectory> 
	            </configuration>           
			</plugin>
		</plugins>
	</build>
</project>


 
 

有个为题,为什么reportng包,放在本地依赖就一直出现问题呢? 我已经将reportng依赖的包的放在了dependencys 中了。而直接依赖reportng就可以运行呢?先记录下

错误 :  Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test (default-test) on project sele: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test failed: There was an error in the forked process

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值