*/
public SimpleTest(String name) {
super(name);
// TODO Auto-generated constructor stub
}
/*
* (non-Javadoc)
*
* @see junit.framework.TestCase#setUp()
*/
protected void setUp() throws Exception {
super.setUp();
}
/*
* (non-Javadoc)
*
* @see junit.framework.TestCase#tearDown()
*/
protected void tearDown() throws Exception {
super.tearDown();
}
public void testEmptyCollection() {
Collection collection = new ArrayList();
assertTrue(collection.isEmpty());
}
public void testPlus() {
assertTrue(2==(1+1));
}
public static Test suite() {
return new TestSuite(SimpleTest.class);
}
public static void main(String args[]) {
junit.textui.TestRunner.run(suite());
}
文章来源于领测软件测试网 https://www.ltesting.net/