teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

2

追記

2018/12/07 13:02

投稿

yukkuri
yukkuri

スコア624

title CHANGED
File without changes
body CHANGED
@@ -81,18 +81,15 @@
81
81
  ```
82
82
  <project name="Jyl Library" default="versionInfo" basedir=".">
83
83
 
84
- <target name="versionInfo">
84
+ <path id = "junit">
85
+ <pathelement location="/home/pi/Desktop/JylLibrary/junit.jar"/>
86
+ </path>
85
87
 
86
- <!-- 省略 -->
87
-
88
- </target>
89
-
90
-
91
88
  <target name="compile" depends="versionInfo">
92
89
 
93
90
  <javac srcdir="org" debug="true" includeAntRuntime="yes">
94
91
  <classpath>
95
- <path path="/home/pi/Desktop/JylLibrary/junit.jar"/>
92
+ <path refid="junit"/>
96
93
  </classpath>
97
94
  </javac>
98
95
 

1

追記

2018/12/07 13:02

投稿

yukkuri
yukkuri

スコア624

title CHANGED
File without changes
body CHANGED
@@ -76,6 +76,49 @@
76
76
  </project>
77
77
  ```
78
78
 
79
+
80
+ 試行錯誤したあと
81
+ ```
82
+ <project name="Jyl Library" default="versionInfo" basedir=".">
83
+
84
+ <target name="versionInfo">
85
+
86
+ <!-- 省略 -->
87
+
88
+ </target>
89
+
90
+
91
+ <target name="compile" depends="versionInfo">
92
+
93
+ <javac srcdir="org" debug="true" includeAntRuntime="yes">
94
+ <classpath>
95
+ <path path="/home/pi/Desktop/JylLibrary/junit.jar"/>
96
+ </classpath>
97
+ </javac>
98
+
99
+ </target>
100
+
101
+
102
+ <target name="UnitTest" depends="compile">
103
+
104
+ <junit>
105
+
106
+ <formatter type="xml"/>
107
+
108
+ <classpath>
109
+
110
+ <fileset dir="." includes="junit.jar"/>
111
+
112
+ </classpath>
113
+
114
+ <test name="org.jyl.base.utest.JylFrameTest.java"/>
115
+
116
+ </junit>
117
+
118
+ </target>
119
+
120
+ </project>
121
+ ```
79
122
  ### 試したこと
80
123
 
81
124
  classpath や パスを絶対パスにしてみたりした -> 実行できたものもあったが