1 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 2 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 3 <modelVersion>4.0.0</modelVersion> 4 5 <groupId>shuanghe</groupId> 6 <artifactId>medicine</artifactId> 7 <version>0.0.1-SNAPSHOT</version> 8 <packaging>jar</packaging> 9 <!-- maven 运行测试name --> 10 <name>medicine</name> 11 <url>http://maven.apache.org</url> 12 13 <properties> 14 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 15 </properties> 16 17 <dependencies> 18 <!-- 单元测试框架 --> 19 <dependency> 20 <groupId>junit</groupId> 21 <artifactId>junit</artifactId> 22 <version>3.8.1</version> 23 <scope>test</scope> 24 </dependency> 25 <!-- httpclient接口请求依赖的jar --> 26 <dependency> 27 <groupId>org.apache.httpcomponents</groupId> 28 <artifactId>httpclient</artifactId> 29 <version>4.5.2</version> 30 </dependency> 31 <!-- testNg单元测试框架 --> 32 <!-- https://mvnrepository.com/artifact/org.testng/testng --> 33 <dependency> 34 <groupId>org.testng</groupId> 35 <artifactId>testng</artifactId> 36 <version>6.9.10</version> 37 <scope>test</scope> 38 </dependency> 39 <!-- 打印测试日志 --> 40 <!-- https://mvnrepository.com/artifact/log4j/log4j --> 41 <dependency> 42 <groupId>log4j</groupId> 43 <artifactId>log4j</artifactId> 44 <version>1.2.17</version> 45 </dependency> 46 <!-- 对象解析工具--> 47 <dependency> 48 <groupId>com.alibaba</groupId> 49 <artifactId>fastjson</artifactId> 50 <version>1.2.47</version> 51 </dependency> 52 <dependency> 53 <groupId>org.json</groupId> 54 <artifactId>json</artifactId> 55 <version>20180813</version> 56 </dependency> 57 <!-- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore --> 58 <dependency> 59 <groupId>org.apache.httpcomponents</groupId> 60 <artifactId>httpcore</artifactId> 61 <version>4.4.10</version> 62 </dependency> 63 <!-- 读取excel数据--> 64 <dependency> 65 <groupId>net.sourceforge.jexcelapi</groupId> 66 <artifactId>jxl</artifactId> 67 <version>2.6.12</version> 68 </dependency> 69 <!-- 导入excel模板依赖--> 70 <dependency> 71 <groupId>org.apache.poi</groupId> 72 <artifactId>poi-ooxml</artifactId> 73 <version>3.17</version> 74 </dependency> 75 <!-- 输出测试报告 关联testNg--> 76 <dependency> 77 <groupId>org.uncommons</groupId> 78 <artifactId>reportng</artifactId> 79 <version>1.1.4</version> 80 <exclusions> 81 <exclusion> 82 <groupId>org.testng</groupId> 83 <artifactId>testng</artifactId> 84 </exclusion> 85 </exclusions> 86 </dependency> 87 <!-- reportng报告依赖的模板velocity-dep--> 88 <dependency> 89 <groupId>velocity</groupId> 90 <artifactId>velocity-dep</artifactId> 91 <version>1.4</version> 92 </dependency> 93 <!-- 依赖注入框架 --> 94 <dependency> 95 <groupId>com.google.inject</groupId> 96 <artifactId>guice</artifactId> 97 <version>4.0</version> 98 </dependency> 99 </dependencies> 100 <build> 101 <plugins> 102 <!-- maven命令执行单元测试时,需要关联testNg.xml的插件 --> 103 <plugin> 104 <groupId>org.apache.maven.plugins</groupId> 105 <artifactId>maven-surefire-plugin</artifactId> 106 <version>2.21.0</version> 107 <configuration> 108 <testFailureIgnore>true</testFailureIgnore> 109 <suiteXmlFiles> 110 <!--该文件位于工程根目录时,直接填写名字,其它位置要加上路径 --> 111 <suiteXmlFile>testng.xml</suiteXmlFile> 112 <!-- 调用<proproperties><suiteXmlFile>res/${xmlFileName}</suiteXmlFile> --> 113 </suiteXmlFiles> 114 </configuration> 115 </plugin> 116 117 </plugins> 118 </build> 119 </project>
pom.xml配置
猜你喜欢
转载自www.cnblogs.com/cty136/p/11533199.html
今日推荐
周排行