Software Testing_Lab 1 Junit and Eclemma

1. Install Junit(4.12), Hamcrest(1.3) with Eclipse

1.1 download Junit(4.12), Hamcrest(1.3)

 

1.2 Click the project with the right button, select properties ->Java Build Path ->Libraries->Add external JARs

Then select the junit-4.12.jar and Hamcrest-core-1.3

 

2. Install Eclemma with Eclipse

2.1. Put the Eclemma.zip under the directory

2.2. Click help->install new software->add

 

3.Write a java program for the triangle problem and test the program with junit.

3.1. Build a project and  Write the code.

3.2.Add a source folder which will contain test package and the test class and Write test code

3.3. Run it as JUnit test and use eclemma.

And then put it on GIT.

That's all.

 

posted on 2017-03-13 21:23  byqdns  阅读(67)  评论(0编辑  收藏  举报