01: /* DdBehaviourBase.java
02: *
03: * DDSteps - Data Driven JUnit Test Steps
04: * Copyright (C) 2005 Jayway AB
05: * www.ddsteps.org
06: *
07: * This library is free software; you can redistribute it and/or
08: * modify it under the terms of the GNU Lesser General Public
09: * License version 2.1 as published by the Free Software Foundation.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: *
16: * You should have received a copy of the GNU Lesser General Public
17: * License along with this library; if not, visit
18: * http://www.opensource.org/licenses/lgpl-license.php
19: */
20: package org.ddsteps.junit.behaviour;
21:
22: import junit.framework.TestCase;
23:
24: import org.apache.commons.lang.Validate;
25: import org.apache.commons.logging.Log;
26: import org.apache.commons.logging.LogFactory;
27: import org.ddsteps.data.DataLoader;
28:
29: /**
30: * @author adam
31: * @version $Id: DdBehaviourBase.java,v 1.1 2006/01/29 21:25:39 adamskogman Exp $
32: */
33: public class DdBehaviourBase {
34:
35: /**
36: * Logger
37: */
38: protected static final Log LOG = LogFactory
39: .getLog(DdRowBehaviour.class);
40:
41: /**
42: * Dependency: Test Case
43: */
44: protected TestCase testCase;
45:
46: /**
47: * Property: Method Name
48: */
49: protected String methodName;
50:
51: /**
52: * Dependency: Data Loader
53: */
54: protected DataLoader dataLoader;
55:
56: /**
57: * @param testCase
58: * @param methodName
59: * @param dataLoader
60: */
61: public DdBehaviourBase(TestCase testCase, String methodName,
62: DataLoader dataLoader) {
63: super ();
64: Validate
65: .notNull(testCase, "Argument testCase must not be null");
66: Validate.notNull(methodName,
67: "Argument methodName must not be null");
68: Validate.notNull(dataLoader,
69: "Argument dataLoader must not be null");
70: this.testCase = testCase;
71: this.methodName = methodName;
72: this.dataLoader = dataLoader;
73: }
74:
75: }
|