Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.sun.xacml.test
Class TestDriver  view TestDriver download TestDriver.java

java.lang.Object
  extended bycom.sun.xacml.test.TestDriver

public class TestDriver
extends java.lang.Object

Simple driver class that sets up and runs the tests.


Field Summary
private  com.sun.xacml.PDP pdp
           
private  TestPolicyFinderModule policyModule
           
private  java.util.ArrayList tests
           
 
Constructor Summary
TestDriver(java.lang.String testFile)
          Constructor that sets up the tests for running.
 
Method Summary
private  void configurePDP()
          Private helper that configures the pdp and the factories based on the settings in the run-time configuration file.
private  org.w3c.dom.Node getRootNode(java.lang.String configFile)
          Private helper that parses the file and sets up the DOM tree.
private  void loadTests(java.lang.String testFile)
          Private helper that loads the tree of test cases
static void main(java.lang.String[] args)
          Main-line.
 void runTests(java.lang.String prefix)
          Runs the tests, in order, using the given location of the test data.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

pdp

private com.sun.xacml.PDP pdp

policyModule

private TestPolicyFinderModule policyModule

tests

private java.util.ArrayList tests
Constructor Detail

TestDriver

public TestDriver(java.lang.String testFile)
           throws java.lang.Exception
Constructor that sets up the tests for running.

Method Detail

configurePDP

private void configurePDP()
                   throws java.lang.Exception
Private helper that configures the pdp and the factories based on the settings in the run-time configuration file.


loadTests

private void loadTests(java.lang.String testFile)
                throws java.lang.Exception
Private helper that loads the tree of test cases


getRootNode

private org.w3c.dom.Node getRootNode(java.lang.String configFile)
                              throws java.lang.Exception
Private helper that parses the file and sets up the DOM tree.


runTests

public void runTests(java.lang.String prefix)
Runs the tests, in order, using the given location of the test data.


main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Main-line. The first argument is the file contaning the tests to run, and the second argument is the location of the conformance tests. Both arguments are required.