001: /*
002: * @(#)AutoDocTPUTestI.java
003: *
004: * Copyright (C) 2002-2003 Matt Albrecht
005: * groboclown@users.sourceforge.net
006: * http://groboutils.sourceforge.net
007: *
008: * Permission is hereby granted, free of charge, to any person obtaining a
009: * copy of this software and associated documentation files (the "Software"),
010: * to deal in the Software without restriction, including without limitation
011: * the rights to use, copy, modify, merge, publish, distribute, sublicense,
012: * and/or sell copies of the Software, and to permit persons to whom the
013: * Software is furnished to do so, subject to the following conditions:
014: *
015: * The above copyright notice and this permission notice shall be included in
016: * all copies or substantial portions of the Software.
017: *
018: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
019: * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
020: * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
021: * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
022: * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
023: * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
024: * DEALINGS IN THE SOFTWARE.
025: */
026:
027: package net.sourceforge.groboutils.autodoc.v1;
028:
029: //import net.sourceforge.groboutils.testing.junitlog.v1.*;
030: import org.easymock.EasyMock;
031: import org.easymock.MockControl;
032: import net.sourceforge.groboutils.junit.v1.iftc.*;
033: import junit.framework.Test;
034: import junit.framework.TestCase;
035: import junit.framework.TestSuite;
036:
037: /**
038: * Tests the AutoDocTP interface.
039: *
040: * @author Matt Albrecht <a href="mailto:groboclown@users.sourceforge.net">groboclown@users.sourceforge.net</a>
041: * @since March 27, 2002
042: * @version $Date: 2003/02/10 22:52:15 $
043: */
044: public class AutoDocTPUTestI extends InterfaceTestCase {
045: //-------------------------------------------------------------------------
046: // Standard JUnit Class-specific declarations
047:
048: private static final Class THIS_CLASS = AutoDocTPUTestI.class;
049:
050: // private static final IJUnitDocumentor LOG = (new JUnitLog(THIS_CLASS)).getDocumentor();
051:
052: public AutoDocTPUTestI(String name, ImplFactory f) {
053: super (name, AutoDocTP.class, f);
054: }
055:
056: public AutoDocTP createAutoDocTP() {
057: return (AutoDocTP) createImplObject();
058: }
059:
060: //-------------------------------------------------------------------------
061: // Tests
062:
063: public void testSetupStep1() {
064: AutoDocTP tp = createAutoDocTP();
065: tp.setupStep(null);
066: }
067:
068: public void testSetupStep2() {
069: AutoDocTP tp = createAutoDocTP();
070: tp.setupStep("");
071: }
072:
073: public void testSetupStep3() {
074: AutoDocTP tp = createAutoDocTP();
075: tp.setupStep("asf");
076: }
077:
078: public void testSetupStep4() {
079: AutoDocTP tp = createAutoDocTP();
080: tp.setupStep(" ");
081: }
082:
083: public void testTeardownStep1() {
084: AutoDocTP tp = createAutoDocTP();
085: tp.teardownStep(null);
086: }
087:
088: public void testTeardownStep2() {
089: AutoDocTP tp = createAutoDocTP();
090: tp.teardownStep("");
091: }
092:
093: public void testTeardownStep3() {
094: AutoDocTP tp = createAutoDocTP();
095: tp.teardownStep(" ");
096: }
097:
098: public void testTeardownStep4() {
099: AutoDocTP tp = createAutoDocTP();
100: tp.teardownStep("asdf asdf");
101: }
102:
103: public void testStep1() {
104: AutoDocTP tp = createAutoDocTP();
105: tp.step(null);
106: }
107:
108: public void testStep2() {
109: AutoDocTP tp = createAutoDocTP();
110: tp.step("");
111: }
112:
113: public void testStep3() {
114: AutoDocTP tp = createAutoDocTP();
115: tp.step(" ");
116: }
117:
118: public void testStep4() {
119: AutoDocTP tp = createAutoDocTP();
120: tp.step("asdf asdf");
121: }
122:
123: //-------------------------------------------------------------------------
124: // Standard JUnit declarations
125:
126: public static InterfaceTestSuite suite() {
127: InterfaceTestSuite suite = new InterfaceTestSuite(THIS_CLASS);
128:
129: return suite;
130: }
131:
132: public static void main(String[] args) {
133: String[] name = { THIS_CLASS.getName() };
134:
135: // junit.textui.TestRunner.main( name );
136: // junit.swingui.TestRunner.main( name );
137:
138: junit.textui.TestRunner.main(name);
139: }
140:
141: /**
142: *
143: * @exception Exception thrown under any exceptional condition.
144: */
145: protected void setUp() throws Exception {
146: super .setUp();
147:
148: // set ourself up
149: }
150:
151: /**
152: *
153: * @exception Exception thrown under any exceptional condition.
154: */
155: protected void tearDown() throws Exception {
156: // tear ourself down
157:
158: super.tearDown();
159: }
160: }
|