diff options
| author | Stephen D. Huston <shuston@apache.org> | 2009-10-15 00:38:18 +0000 |
|---|---|---|
| committer | Stephen D. Huston <shuston@apache.org> | 2009-10-15 00:38:18 +0000 |
| commit | 7ae0c86350150e818b70c1305bc5b4e4a3de17df (patch) | |
| tree | be176bad4bcd4a75ec4639f7a54ecd57cd3c4ffa /qpid/cpp/src/tests/topictest.ps1 | |
| parent | 11378edb5d636b0711bfe4a397df4536ca7a014e (diff) | |
| download | qpid-python-7ae0c86350150e818b70c1305bc5b4e4a3de17df.tar.gz | |
Improved test output capturing in automated tests; correctly get exe process exit codes
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@825358 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/topictest.ps1')
| -rw-r--r-- | qpid/cpp/src/tests/topictest.ps1 | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/qpid/cpp/src/tests/topictest.ps1 b/qpid/cpp/src/tests/topictest.ps1 index 58ae50c67c..0d22cea657 100644 --- a/qpid/cpp/src/tests/topictest.ps1 +++ b/qpid/cpp/src/tests/topictest.ps1 @@ -18,6 +18,7 @@ # # Run the C++ topic test +$srcdir = Split-Path $myInvocation.InvocationName # Parameters with default values: s (subscribers) m (messages) b (batches) # h (host) t (false; use transactions) @@ -36,21 +37,23 @@ if ($t) { $transactional = "--transactional --durable" } +# Find which subdir the exes are in +. $srcdir\find_prog.ps1 .\topic_listener.exe + function subscribe { param ([int]$num) "Start subscriber $num" $LOG = "subscriber_$num.log" - $cmdline = "$env:OUTDIR\topic_listener $transactional > $LOG 2>&1 + $cmdline = ".\$sub\topic_listener $transactional > $LOG 2>&1 if (`$LastExitCode -ne 0) { Remove-Item $LOG }" $cmdblock = $executioncontext.invokecommand.NewScriptBlock($cmdline) . $srcdir\background.ps1 $cmdblock } function publish { - Invoke-Expression "$env:OUTDIR\topic_publisher --messages $messages --batches $batches --subscribers $subscribers $host $transactional" 2>&1 + Invoke-Expression ".\$sub\topic_publisher --messages $messages --batches $batches --subscribers $subscribers $host $transactional" 2>&1 } -$srcdir = Split-Path $MyInvocation.MyCommand.Path if ($broker.length) { $broker = "-h$broker" } |
