Skip to content
Snippets Groups Projects
Commit 586342c6 authored by Jan David Mol's avatar Jan David Mol
Browse files

Task #7350: Fixed tMACfeedback to use full path to qpid-receive

parent f24e7055
No related branches found
No related tags found
No related merge requests found
......@@ -4624,6 +4624,7 @@ SubSystems/Online_Cobalt/test/Correlator/tCorrelate_3sec_2st_5sb.sh eol=lf
SubSystems/Online_Cobalt/test/tMACfeedback.in_parset_failure_1 -text
SubSystems/Online_Cobalt/test/tMACfeedback.in_parset_success_1 -text
SubSystems/Online_Cobalt/test/tMACfeedback.run eol=lf
SubSystems/Online_Cobalt/test/tMACfeedback.run2.in eol=lf
SubSystems/Online_Cobalt/test/tMACfeedback.sh eol=lf
SubSystems/Online_Cobalt/test/tProductionParsets.in_parsets/CorrProc_173014.param -text
SubSystems/Online_Cobalt/test/tProductionParsets.in_parsets/CorrProc_196344-CygAf009-225SAPS.cleaned.param -text
......
......@@ -2,10 +2,10 @@
include(LofarCTest)
foreach(_file testFuncs runtest)
foreach(_file testFuncs.sh runtest.sh tMACfeedback.run2)
configure_file(
${CMAKE_CURRENT_SOURCE_DIR}/${_file}.sh.in
${CMAKE_CURRENT_BINARY_DIR}/${_file}.sh @ONLY)
${CMAKE_CURRENT_SOURCE_DIR}/${_file}.in
${CMAKE_CURRENT_BINARY_DIR}/${_file} @ONLY)
endforeach()
set(_tests
......
#!/bin/bash
. ./testFuncs.sh
function test_parset {
PARSET="$1"
EXPECTED_OBSRESULT="$2"
EXTRA_PARAMS="$3"
echo "Testing $PARSET, expecting result $EXPECTED_OBSRESULT"
# Add the connection information for this test
echo "Cobalt.FinalMetaDataGatherer.host=localhost" >> $PARSET
# Run the observation
runObservation.sh -B -C -l 1 $EXTRA_PARAMS $PARSET
OBSRESULT=$?
if [ $OBSRESULT -ne $EXPECTED_OBSRESULT ]; then
echo "runObservation.sh failed (status: $OBSRESULT)"
exit 1
fi
# Pull the message from the status queue
qpid-receive -b 127.0.0.1 -q lofar.task.feedback.status || error 'Could not pull status message from bus'
# Check the message against the expected result
# <TODO>
}
test_parset $PWD/tMACfeedback.in_parset_success_1 0 ""
test_parset $PWD/tMACfeedback.in_parset_failure_1 1 "-o Cobalt.Nodes=[unreachable]"
# Everything went ok
exit 0
#!/bin/sh
./tMACfeedback.run2
#!/bin/bash
. ./testFuncs.sh
function test_parset {
PARSET="$1"
EXPECTED_OBSRESULT="$2"
EXTRA_PARAMS="$3"
echo "Testing $PARSET, expecting result $EXPECTED_OBSRESULT"
# Add the connection information for this test
echo "Cobalt.FinalMetaDataGatherer.host=localhost" >> $PARSET
# Run the observation
runObservation.sh -B -C -l 1 $EXTRA_PARAMS $PARSET
OBSRESULT=$?
if [ $OBSRESULT -ne $EXPECTED_OBSRESULT ]; then
echo "runObservation.sh failed (status: $OBSRESULT)"
exit 1
fi
# Pull the message from the status queue
@QPID_RECEIVE_EXECUTABLE@ -b 127.0.0.1 -q lofar.task.feedback.status || error 'Could not pull status message from bus'
# Check the message against the expected result
# <TODO>
}
test_parset $PWD/tMACfeedback.in_parset_success_1 0 ""
test_parset $PWD/tMACfeedback.in_parset_failure_1 1 "-o Cobalt.Nodes=[unreachable]"
# Everything went ok
exit 0
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment