public class HTMLTestFinder extends TestFinder
TestFinder
TestFinder.ErrorHandler, TestFinder.Fault
Modifier and Type | Field and Description |
---|---|
static int |
DIR_WALK
A value for
setMode(int) to specify that the child files
within the test tree should be determined by sub-directories and
HTML files within directories. |
static int |
WEB_WALK
A value for
setMode(int) to specify that the child files
within the test tree should be determined from the HTML <a href=...> tags. |
debug, env
Constructor and Description |
---|
HTMLTestFinder()
Create an HTMLTestFinder.
|
Modifier and Type | Method and Description |
---|---|
protected int |
decodeArg(java.lang.String[] args,
int i)
Decode the arg at a specified position in the arg array.
|
protected java.io.File |
getCurrentFile()
Get the name of the file currently being read.
|
int |
getMode()
Get the current mode for how this test finder determines the child files
to be scanned.
|
java.io.File |
getRoot()
Get the root file of the test suite, as passed in to the
init method. |
protected void |
localizedError(java.lang.String msg)
Report a message to the error handler, without additional processing.
|
protected void |
scan(java.io.File file)
Scan a file, looking for test descriptions and other files that might
need to be scanned.
|
void |
setMode(int mode)
Specify the mode for how this test finder determines the child files
to be scanned.
|
clearErrors, decodeAllArgs, error, error, error, foundFile, foundTestDescription, foundTestDescription, getComparator, getDefaultComparator, getErrorCount, getErrorHandler, getErrors, getFiles, getRootDir, getTests, init, init, isFolder, lastModified, normalize, processEntry, read, setComparator, setErrorHandler, setRoot
public static final int WEB_WALK
setMode(int)
to specify that the child files
within the test tree should be determined from the HTML <a href=...> tags.public static final int DIR_WALK
setMode(int)
to specify that the child files
within the test tree should be determined by sub-directories and
HTML files within directories.protected int decodeArg(java.lang.String[] args, int i) throws TestFinder.Fault
TestFinder
decodeArg
in class TestFinder
args
- The array of argumentsi
- The next argument to be decodedTestFinder.Fault
- If there is a problem with the value of the current
arg, such as a bad value to an option, the Fault
exception can be thrown. The exception should NOT be
thrown if the current arg is unrecognized: in that case,
an implementation should delegate the call to the
supertype.public java.io.File getRoot()
TestFinder
init
method.getRoot
in class TestFinder
TestFinder.setRoot(java.io.File)
protected void localizedError(java.lang.String msg)
TestFinder
localizedError
in class TestFinder
msg
- The message to be reportedTestFinder.error(com.sun.javatest.util.I18NResourceBundle, java.lang.String)
public void setMode(int mode)
public int getMode()
WEB_WALK
or DIR_WALK
setMode(int)
protected void scan(java.io.File file)
TestFinder
scan
in class TestFinder
file
- The file to scanprotected java.io.File getCurrentFile()
Copyright (c) 1996, 2015, Oracle and/or its affiliates. All rights reserved.