net.sf.jameleon.bean
Class TestCase

java.lang.Object
  extended by net.sf.jameleon.bean.TestCase
All Implemented Interfaces:
Serializable, XMLable

public class TestCase
extends Object
implements XMLable

This class represents a test case. This is currently used only for test case documentation generation A TestCase consists of:

See Also:
Serialized Form

Field Summary
protected  String application
          The application being tested
protected  String author
          The person that wrote the test case
protected  Set bugs
          The bug related to this test case
protected  String encoding
          The encoding to use in the toXML() method
protected  String file
          The test case file
protected  String functionalPointTested
          The functional point tested by the test case
protected  String name
          The name of the test case
protected  String organization
          The organization the test case is set to execute against.
protected  List sessions
          A list of sessions in this test case
protected  String summary
          A brief description of the test case
protected  String testCaseId
          The unique id of the test case.
protected  String testCaseRequirement
          The link to the requirement being tested
protected  String testEnvironment
          The test evironment this test case is being test against
protected  List testLevels
          The level(s) of the test case - SMOKE, FUNCTIONAL, REGRESSION, ACCEPTANCE, to list a few
 
Constructor Summary
TestCase()
          Default constructor only used to initialize variables
 
Method Summary
 void addBug(String bug)
           
 void addSession(Session s)
           
 void addTestLevel(String testLevel)
           
 String getApplication()
           
 String getAuthor()
           
 Set getBugs()
           
 String getEncoding()
           
 String getFile()
           
 String getFunctionalPointTested()
           
 String getName()
           
 String getOrganization()
           
 String getScriptContents()
           
 List getSessions()
           
 String getSummary()
           
 String getTestCaseId()
           
 String getTestCaseRequirement()
           
 String getTestEnvironment()
           
 List getTestLevels()
           
 void readFromScript(String script)
          Populates this test case object from a test script script
 void setApplication(String application)
           
 void setAuthor(String author)
           
 void setEncoding(String encoding)
          Sets the encoding to use in the toXML() results
 void setFile(String file)
           
 void setFunctionalPointTested(String functionalPointTested)
           
 void setName(String name)
           
 void setOrganization(String organization)
           
 void setSummary(String summary)
           
 void setTestCaseId(String testCaseId)
           
 void setTestCaseRequirement(String testCaseRequirement)
           
 void setTestEnvironment(String testEnvironment)
           
 void setTestLevels(LinkedList testLevels)
           
 String toXML()
          Implement this method the same way the toString method would be implemented, except the object's information should be in a valid XML format.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

name

protected String name
The name of the test case


summary

protected String summary
A brief description of the test case


author

protected String author
The person that wrote the test case


application

protected String application
The application being tested


bugs

protected Set bugs
The bug related to this test case


functionalPointTested

protected String functionalPointTested
The functional point tested by the test case


testLevels

protected List testLevels
The level(s) of the test case - SMOKE, FUNCTIONAL, REGRESSION, ACCEPTANCE, to list a few


file

protected String file
The test case file


encoding

protected String encoding
The encoding to use in the toXML() method


testCaseId

protected String testCaseId
The unique id of the test case.


organization

protected String organization
The organization the test case is set to execute against.


testCaseRequirement

protected String testCaseRequirement
The link to the requirement being tested


testEnvironment

protected String testEnvironment
The test evironment this test case is being test against


sessions

protected List sessions
A list of sessions in this test case

Constructor Detail

TestCase

public TestCase()
Default constructor only used to initialize variables

Method Detail

addBug

public void addBug(String bug)

addSession

public void addSession(Session s)

addTestLevel

public void addTestLevel(String testLevel)

getApplication

public String getApplication()

getAuthor

public String getAuthor()

getBugs

public Set getBugs()

getEncoding

public String getEncoding()
Returns:
the encoding style to use in the toXML() method

getFile

public String getFile()

getScriptContents

public String getScriptContents()

getFunctionalPointTested

public String getFunctionalPointTested()

getName

public String getName()

getOrganization

public String getOrganization()

getSessions

public List getSessions()

getSummary

public String getSummary()

getTestCaseId

public String getTestCaseId()

getTestCaseRequirement

public String getTestCaseRequirement()

getTestEnvironment

public String getTestEnvironment()

getTestLevels

public List getTestLevels()

readFromScript

public void readFromScript(String script)
Populates this test case object from a test script script


setApplication

public void setApplication(String application)

setAuthor

public void setAuthor(String author)

setEncoding

public void setEncoding(String encoding)
Sets the encoding to use in the toXML() results

Parameters:
encoding - - the encoding to use in the toXML() results

setFile

public void setFile(String file)

setFunctionalPointTested

public void setFunctionalPointTested(String functionalPointTested)

setName

public void setName(String name)

setOrganization

public void setOrganization(String organization)

setSummary

public void setSummary(String summary)

setTestCaseId

public void setTestCaseId(String testCaseId)

setTestCaseRequirement

public void setTestCaseRequirement(String testCaseRequirement)

setTestEnvironment

public void setTestEnvironment(String testEnvironment)

setTestLevels

public void setTestLevels(LinkedList testLevels)

toXML

public String toXML()
Description copied from interface: XMLable
Implement this method the same way the toString method would be implemented, except the object's information should be in a valid XML format.

Specified by:
toXML in interface XMLable


Copyright © 2003-2008 Christian Hargraves. All Rights Reserved.