|
|||||||||
| Home >> All >> com >> tripi >> asp >> [ test overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
com.tripi.asp.test
Class AspTest

java.lang.Objectcom.tripi.asp.test.AspTest
- public class AspTest
- extends java.lang.Object
AspTest executes an ASP script directly like a command script.
Usage: java com.tripi.asp.AspTest <filename>
Where filename is the name of the file.
- Version:
- 0.9
| Field Summary | |
(package private) static org.apache.log4j.Category |
DBG
Debugging category |
(package private) static java.lang.String |
param_log4j
Log4j file to use |
| Constructor Summary | |
AspTest()
|
|
| Method Summary | |
static boolean |
compare(java.lang.String content,
java.lang.String filename)
Compares the text to the give template. |
private static void |
displayHelp()
Displays the help information file. |
static boolean |
doSimpleFailureTest(java.lang.String directory,
java.lang.String name)
Performs a simple output test, which will be a error. |
static boolean |
doSimpleTest(java.lang.String directory,
java.lang.String name)
Performs a simple output test. |
static java.net.URLConnection |
getConnection(java.lang.String location)
Obtains the connection for the given relative URL. |
static java.lang.String |
getContent(java.io.InputStream is)
Gets the full content of the data read in from an input stream. |
static java.lang.String |
getContent(java.net.URLConnection con)
Gets the full content of this URL connection. |
static java.lang.String |
getCookie(java.net.URLConnection con,
java.lang.String name)
Gets a cookie by name. |
static com.tripi.asp.Response |
getResponse(com.tripi.asp.AspContext context)
This function returns the ASP Response object, for testing. |
static java.lang.Object |
getValue(com.tripi.asp.AspContext context,
java.lang.String name)
This function is a utility function to obtain the value of a variable in a context. |
static void |
main(java.lang.String[] args)
Entry point. |
private static void |
parseParameters(java.lang.String[] args)
Parameter parser. |
static void |
save(java.lang.String content,
java.lang.String filename)
Saves the text of an output test case. |
static junit.framework.Test |
suite()
Test suite |
static void |
writeContent(java.net.URLConnection con,
java.lang.String str)
Writes the full content to the URL connection. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
DBG
static final org.apache.log4j.Category DBG
- Debugging category
param_log4j
static java.lang.String param_log4j
- Log4j file to use
| Constructor Detail |
AspTest
public AspTest()
| Method Detail |
displayHelp
private static void displayHelp()
- Displays the help information file.
parseParameters
private static void parseParameters(java.lang.String[] args)
- Parameter parser.
main
public static void main(java.lang.String[] args)
- Entry point.
suite
public static junit.framework.Test suite()
- Test suite
getResponse
public static com.tripi.asp.Response getResponse(com.tripi.asp.AspContext context) throws com.tripi.asp.AspException
- This function returns the ASP Response object, for testing.
getValue
public static java.lang.Object getValue(com.tripi.asp.AspContext context, java.lang.String name) throws com.tripi.asp.AspException
- This function is a utility function to obtain the value of a
variable in a context.
getConnection
public static java.net.URLConnection getConnection(java.lang.String location) throws java.net.MalformedURLException, java.io.IOException
- Obtains the connection for the given relative URL.
save
public static void save(java.lang.String content, java.lang.String filename) throws java.io.IOException
- Saves the text of an output test case.
compare
public static boolean compare(java.lang.String content, java.lang.String filename) throws java.io.IOException
- Compares the text to the give template.
doSimpleTest
public static boolean doSimpleTest(java.lang.String directory, java.lang.String name) throws java.net.MalformedURLException, java.io.IOException
- Performs a simple output test.
doSimpleFailureTest
public static boolean doSimpleFailureTest(java.lang.String directory, java.lang.String name) throws java.net.MalformedURLException, java.io.IOException
- Performs a simple output test, which will be a error.
getContent
public static java.lang.String getContent(java.io.InputStream is) throws java.io.IOException
- Gets the full content of the data read in from an input stream.
getContent
public static java.lang.String getContent(java.net.URLConnection con) throws java.io.IOException
- Gets the full content of this URL connection.
writeContent
public static void writeContent(java.net.URLConnection con, java.lang.String str) throws java.io.IOException
- Writes the full content to the URL connection.
getCookie
public static java.lang.String getCookie(java.net.URLConnection con, java.lang.String name) throws java.io.IOException
- Gets a cookie by name.
|
|||||||||
| Home >> All >> com >> tripi >> asp >> [ test overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
com.tripi.asp.test.AspTest