0
현재 Fest Junit 테스트 케이스를 작성 중이며 나중에 Hudson 테스트 서버에서 실행됩니다. 테스트 케이스가 실패하면 데스크탑 스크린 샷을 찍도록하고 싶습니다. 이 URL을 설정하는 방법에 대한 자습서가 있습니다. http://fest.codehaus.org/Taking+Screenshots+of+JUnit+Test+Failures하지만 테스트는 로컬에서 실행되지 않습니다. 내가 실행하려고하고Failed Fest JUnit 테스트 스크린 샷
@RunWith(GUITestRunner.class)
public class AddingNewUserTest extends FestTest {
@Before
public void setup(){
super.setup(constants.users.name);
}
@After
public void cleanup(){super.shutDown();
}
@GUITest
public void testAddingNewUser() throws InterruptedException{
//java code
}
그리고 내 JUnit을 개미 작업을 : 여기
내가 실행하려고하고있는 자바 코드의 아래로 미끄러 져 사본입니다<target name="run.tests" description="Runs all the junit tests.">
<echo message="Run the tests"/>
<taskdef resource="festjunittasks" classpathref="classpath" />
<junit printsummary="true" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="yes">
<classpath refid="classpath" />
<formatter classname="org.fest.swing.junit.ant.ScreenshotOnFailureResultFormatter" extension=".xml" />
<batchtest todir="${test.output.reports.test.dir}" unless="testcase" fork="true">
<fileset dir="${output.mainclasses.dir}" includes="**/AddingNewUserTest.class" excludes="**/FestTest.class,**/DefaultsTest.class"/>
</batchtest>
</junit>
<festreport todir="${test.output.reports.dir}">
<classpath refid="classpath" />
<fileset dir="${test.output.reports.test.dir}">
<include name="TEST-*.xml" />
</fileset>
<report format="frames" todir="${test.output.reports.dir}/html" />
</festreport>
<antcall target="kill.server"/>
</target>
어떤 도움이 것 잘해라.
보고서 여기