diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2012-01-17 20:44:26 -0500 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2012-01-17 20:44:26 -0500 |
commit | 2ae9f921f2e1d6bd10e4c334a19312761a914046 (patch) | |
tree | 3a184a669955ac35a0898da88e2cb5962f2f05d7 /indra/lib/python | |
parent | 51b26cab9ad8dc54277c6158ad40afdf3ed0e6d0 (diff) |
Refactor llprocesslauncher_test.cpp for better code reuse.
Instead of free python() and python_out() functions containing a local
temporary LLProcessLauncher instance, with a 'tweak' callback param to
"do stuff" to that inaccessible object, change to a PythonProcessLauncher
class that sets up a (public) LLProcessLauncher member, then allows you to
run() or run() and then readfile() the output. Now you can construct an
instance and tweak to your heart's content -- without funky callback syntax --
before running the script.
Move all such helpers from TUT fixture struct to namespace scope. While
fixture-struct methods can freely call one another, introducing a nested class
gets awkward: constructor must explicitly require and bind a fixture-struct
pointer or reference. Namespace scope solves this.
(Truthfully, I only put them in the fixture struct originally because I
thought it necessary for calling ensure() et al. But ensure() and friends are
free functions; need only qualify them with tut:: namespace.)
Diffstat (limited to 'indra/lib/python')
0 files changed, 0 insertions, 0 deletions