Commit 0791c9b3 authored by Andrea Sciaba's avatar Andrea Sciaba
Browse files

HTML-compliant output

parent c766f9de
......@@ -16,16 +16,16 @@ echo "</pre>"
echo "<h3>Sourcing the CMS environment</h3>"
export SCRAM_ARCH=slc4_ia32_gcc345
if [ -n "$OSG_APP" ] ; then
echo "This is an OSG site"
echo "<p>This is an OSG site</p>"
SW_DIR=$OSG_APP/cmssoft/cms
source $OSG_GRID/setup.sh
result=$?
elif [ -n "$VO_CMS_SW_DIR" ] ; then
echo "This is an LCG site"
echo "<p>This is an LCG site</p>"
SW_DIR=$VO_CMS_SW_DIR
result=$?
else
echo "ERROR: neither VO_CMS_SW_DIR nor OSG_APP defined"
echo "<p>ERROR: neither VO_CMS_SW_DIR nor OSG_APP defined</p>"
exit $SAME_ERROR
fi
echo "<pre>"
......@@ -34,7 +34,7 @@ result=$(expr $? + $result)
echo "</pre>"
if [ $result != 0 ]
then
echo "ERROR: $VO_CMS_SW_DIR/cmsset_default.sh non existent or non readable"
echo "<p>ERROR: $VO_CMS_SW_DIR/cmsset_default.sh non existent or non readable</p>"
exit $SAME_ERROR
fi
......@@ -46,32 +46,30 @@ echo "PYTHONPATH=$PYTHONPATH"
echo "</pre>"
echo "<h3>Invoking site test</h3>"
echo "<pre>"
echo "<h5>"
echo "USER/WHOAMI?:" $USER/`whoami`
echo "USER ID:" $UID
voms-proxy-info -all
echo "</h5>"
echo "</pre>"
cd $SAME_SENSOR_HOME/cms-MC-test/
if [ $? -ne 0 ]; then
echo "ERROR: Could not access the cms-MC-test directory"
echo "<p>ERROR: Could not access the cms-MC-test directory</p>"
exit $SAME_ERROR
else
echo "<pre>"
chmod u+x RuntimeSAMStageOut.py
./RuntimeSAMStageOut.py 2>&1
./RuntimeSAMStageOut.py | sed -e 's/&/&amp;/g' 2>&1
EXIT_STATUS=$?
fi
echo "</pre>"
if [ $EXIT_STATUS -ne 0 -a $EXIT_STATUS -ne 4 ] ; then
echo "ERROR: Stage Out Test failed: $EXIT_STATUS"
echo "<p>ERROR: Stage Out Test failed: $EXIT_STATUS</p>"
exit $SAME_ERROR
elif [ $EXIT_STATUS -eq 4 ]; then
echo "WARNING: Stage Out Test failed to cleanup the test file: $EXIT_STATUS"
echo "<p>WARNING: Stage Out Test failed to cleanup the test file: $EXIT_STATUS</p>"
exit $SAME_WARNING
else
echo "Stage Out Test successful"
echo "<p>Stage Out Test successful</p>"
exit $SAME_OK
fi
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment