安装TestNG
1、帮助 - install new software
2、在work with输入框的右边,点击add,弹出弹窗,在name中输入“TestNG",在Location中输入“http://beust.com/eclipse”, 点击add按钮
3、勾选TestNG,点击next,同意协议,重启eclipse
创建testng的class
1、在工程上右键 底部有个“TestNG”
或者:工程上右键 new -other -testng
2、勾选annotations前2排,且在xml suit file中输入 testng.xml(可以随意命名)
注解:(来自易白的介绍: