01: /**
02: * Copyright (C) 2007 NetMind Consulting Bt.
03: * All rights reserved.
04: */package hu.netmind.persistence;
05:
06: import junit.framework.Test;
07: import junit.textui.ResultPrinter;
08: import java.io.PrintStream;
09:
10: /**
11: * ANSI terminal test runner class.
12: * @author Brautigam Robert
13: * @version Revision: $Revision$
14: */
15: public class ANSIResultPrinter extends ResultPrinter {
16: private int column = 0;
17:
18: public ANSIResultPrinter(PrintStream writer) {
19: super (writer);
20: }
21:
22: public void startTest(Test test, long runtime) {
23: getWriter().print(".");
24: getWriter().flush();
25: if (column++ >= 40) {
26: getWriter().println();
27: column = 0;
28: }
29: }
30: }
|