我從字面上浪費了2個小時試圖讓ant junit任務工作。首先,我無法找到ant-junit.jar
文件,但我設法在maven頁面中找到它。從那以後,我把它放在幾個地方(~/.ant/lib
,/usr/share/ant/lib
),但沒有運氣..我仍然收到此錯誤:ant junit任務 - 在哪裏下載ant-junit.jar以及在哪裏放置它?
Cause: the class org.apache.tools.ant.taskdefs.optional.junit.JUnitTask was not found.
This looks like one of Ant's optional components.
所以我在尋找:
- 官方網頁下載ant junit任務文件
- 放置該文件的正確位置。