Version 1 (modified by rlaher, 11 years ago) (diff)


Simple Stage Tester

A new, simple Stage tester is available in recent pex_harness releases. An example of its use can be found in $PEX_HARNESS_DIR/examples/ You can run the example without arguments:

    setup pex_harness
    python $PEX_HARNESS_DIR/examples/

It is fully annotated with in-lined comments and shows how you can create a simple script that executes a Stage with a given set of inputs. I hope this will be a useful debugging tool.

This example script includes a sample implementation of a Stage, and in the latest release I've expanded this example as an aid for creating Stage implementations. While most of the Stages for DC3a are for the most part written, you may still find this helpful to see how to:

  • Incorporate logging (with log and debug messages)
  • Retrieve default policy data and merge it into the policy

passed in by the framework.

Let Ray Plante know if you have any questions on or suggestions for this example.