Commit 400765e2 authored by Christian Glusa's avatar Christian Glusa

Revert "MueLu: Add test that checks if the update_params.sh script has been used"

This reverts commit 6049d843.

Need to check whether xsltproc is available.

Build/Test Cases Summary
Enabled Packages: MueLu
Disabled Packages: PyTrilinos,Claps,TriKota
Enabled all Forward Packages
0) MPI_RELEASE_DEBUG_SHARED_PT => passed: passed=491,notpassed=0 (14.39 min)
parent 6049d843
......@@ -14,5 +14,3 @@ if (${PACKAGE_NAME}_ENABLE_Tutorial)
else()
MESSAGE(STATUS "disabling tutorial")
endif()
ADD_SUBDIRECTORY(UsersGuide)
# copy the scripts
TRIBITS_COPY_FILES_TO_BINARY_DIR(CopyMasterListTest
SOURCE_FILES update_params.sh testMasterList.sh
DEST_FILES update_params.sh ${PACKAGE_NAME}_testMasterList.sh
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}
DEST_DIR ${CMAKE_CURRENT_BINARY_DIR}
)
# copy the input files
SET(TEX "")
SET(XSL "")
FILE(GLOB TEX RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.tex)
FILE(GLOB XSL RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.xsl)
TRIBITS_COPY_FILES_TO_BINARY_DIR(CopyMasterListTestFiles
SOURCE_FILES ${TEX} ${XSL} masterList.xml
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}
DEST_DIR ${CMAKE_CURRENT_BINARY_DIR}
)
TRIBITS_COPY_FILES_TO_BINARY_DIR(CopyMasterListTestCpp
SOURCE_FILES ../../src/MueCentral/MueLu_MasterList.cpp
DEST_FILES MueLu_MasterList.cpp.repo
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}
DEST_DIR ${CMAKE_CURRENT_BINARY_DIR}
)
TRIBITS_ADD_TEST(
testMasterList.sh
NOEXESUFFIX
NAME "MasterList"
NUM_MPI_PROCS 1
)
#!/bin/bash
diff_command="diff -w"
# copy all *.tex to *.tex.gold
shopt -s nullglob
for i in *.tex ; do
cp $i $i.repo
done
# run update script, write MueLu_MasterList.cpp to this folder
./update_params.sh MueLu_MasterList.cpp
# for simplicity, compare all tex files
test_files="*.tex"
test_files+=" MueLu_MasterList.cpp"
return_code=0
for i in $test_files; do
$diff_command $i $i.repo
if [ $? -eq 0 ]; then
echo "$i matches"
else
echo "$i does not match"
return_code=1
fi
done
if [ $return_code -eq 1 ]; then
echo "Do not edit MueLu_MasterList.cpp directly, but edit masterList.xml and run update_params.sh"
fi
exit $return_code
......@@ -3,12 +3,8 @@
xsltproc tex.xsl masterList.xml > paramlist.tex
xsltproc tex_hidden.xsl masterList.xml > paramlist_hidden.tex
if [ "$1" != "" ]; then
code_file=$1
else
code_file="../../src/MueCentral/MueLu_MasterList.cpp"
fi
code_file="../../src/MueCentral/MueLu_MasterList.cpp"
echo '// @HEADER
//
......
Markdown is supported
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