????ant???????

????1.????cd ???????java project?????? cd java project/testSoftware

????2. ????ant ????ant -f build.xml

????3 ?ο????:

Buildfile: /home/xiajian/project file/java project/testSoftware/build.xml
clean:
[delete] Deleting directory /home/xiajian/project file/java project/testSoftware/report
compile:
test:
[mkdir] Created dir: /home/xiajian/project file/java project/testSoftware/report/html
[junit] Running demo2.TestSuite
[junit] Testsuite: demo2.TestSuite
[junit] Tests run: 10?? Failures: 0?? Errors: 0?? Time elapsed: 0.097 sec
[junit] Tests run: 10?? Failures: 0?? Errors: 0?? Time elapsed: 0.097 sec
[junit]
[junit] Testcase: testType[0] took 0.002 sec
[junit] Testcase: testType[1] took 0 sec
[junit] Testcase: testType[2] took 0 sec
[junit] Testcase: testType[3] took 0 sec
[junit] Testcase: testType[4] took 0 sec
[junit] Testcase: testType[5] took 0 sec
[junit] Testcase: testType[6] took 0 sec
[junit] Testcase: testType[7] took 0 sec
[junit] Testcase: testType[8] took 0.001 sec
[junit] Testcase: testType took 0 sec
[junitreport] Processing /home/xiajian/project file/java project/testSoftware/report/TESTS-TestSuites.xml to /tmp/null2022323935
[junitreport] Loading stylesheet jar:file:/usr/share/ant/lib/ant-junit.jar!/org/apache/tools/ant/taskdefs/optional/junit/xsl/junit-frames.xsl
[junitreport] Transform time: 564ms
[junitreport] Deleting: /tmp/null2022323935
report:
[echo] Hello world
BUILD SUCCESSFUL

????ant?????????????????????report????У?????????????????????е????

???????:?????????JUnit??????????????????????????????????????????????????????о???£??????λ??testSoftware/src/demo2????.????????:http://pan.baidu.com/share/link?shareid=1294418402&uk=556148328

?????????????????????????

?????????????OpenJDK 7??????±?д??????????????????Ubuntu12.10????Ubuntu12.04LTS?????????JDK ??Open JDK 6???????????????????java.lang.UnsupportedClassVersionError: demo2/ParameterTestTriangle : Unsupported major.minor version ?????????????????????????:?????????汾??JDK?????Java class??????????汾??JVM??????. ???????:

?????????????????????????

?????滻???????JDK--??JDK??jre???????????(???????????????????build path??build compiler?????)

???????JRE:

????????????:

?????ο?????:

????[1]????????????????/?????? ?廩????????磬 2009.11
????[2] JUnit??(?????)/Peter Tahchiev???????????? ???????????磬2012.4
????[3]???????v?????????:http://leochael.blog.163.com/blog/static/1309571200741181733167/
????[4]?????java????:http://zhidao.baidu.com/question/455404569.html