From 36731b2fe986ea5eff148374183d2ebc6ff1881a Mon Sep 17 00:00:00 2001 From: Will Bainbridge Date: Fri, 24 Jul 2020 12:32:42 +0100 Subject: [PATCH] tutorials: Prevent foamDictionary output from printing during test loop foamDictionary executions are now wrapped by runApplication like any other execution so that they do not print during a test loop. foamDictionary does not produce a conforming log, however, so log.foamDictionary has been filtered out of the formation of the test loop report so that false failures are not reported. --- .../waterAndIsopropanolEvaporation/Allrun | 3 ++- .../interfaceComposition/waterEvaporation/Allrun | 7 ++++--- .../thermal/waterEvaporation/Allrun | 4 ++-- tutorials/Allrun | 4 ++-- tutorials/combustion/XiFoam/RAS/Allrun | 6 +++--- .../reactingFoam/RAS/SandiaD_LTS/Allrun | 16 ++++++++-------- .../chtMultiRegionFoam/coolingSphere/Allrun | 2 +- .../shellAndTubeHeatExchanger/Allmesh.layers | 12 ++++++------ .../pimpleFoam/RAS/flowWithOpenBoundary/Allrun | 2 +- .../simpleFoam/turbineSiting/Allrun | 4 ++-- .../multiphase/interFoam/RAS/DTCHull/Allmesh | 2 +- .../interFoam/RAS/DTCHullMoving/Allmesh | 2 +- .../multiphase/interFoam/RAS/DTCHullWave/Allmesh | 2 +- .../interFoam/RAS/planingHullW3/Allmesh.1 | 2 +- .../interFoam/RAS/planingHullW3/Allmesh.2 | 2 +- .../multiphaseEulerFoam/RAS/wallBoiling/Allrun | 4 ++-- .../RAS/wallBoilingIATE/Allrun | 4 ++-- .../RAS/wallBoilingPolydisperse/Allrun | 4 ++-- .../RAS/wallBoilingPolydisperseTwoGroups/Allrun | 4 ++-- 19 files changed, 44 insertions(+), 42 deletions(-) diff --git a/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterAndIsopropanolEvaporation/Allrun b/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterAndIsopropanolEvaporation/Allrun index 8d344a7838..c3be83fed3 100755 --- a/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterAndIsopropanolEvaporation/Allrun +++ b/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterAndIsopropanolEvaporation/Allrun @@ -14,7 +14,8 @@ setInertY() y=${1%.*} phase=${1#*.} [ $y != "none" ] && arg="-set $y" || arg="-remove" - foamDictionary -entry inertSpecie $arg constant/thermophysicalProperties.$phase + runApplication -a foamDictionary -entry inertSpecie $arg \ + constant/thermophysicalProperties.$phase } for gY in $gYs diff --git a/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterEvaporation/Allrun b/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterEvaporation/Allrun index 2bc8820e03..3fbd8751c5 100755 --- a/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterEvaporation/Allrun +++ b/test/multiphase/multiphaseEulerFoam/interfaceComposition/waterEvaporation/Allrun @@ -18,7 +18,8 @@ setInertY() * ) arg="-set $y";; esac - foamDictionary -entry inertSpecie $arg constant/thermophysicalProperties.$phase + runApplication -a foamDictionary -entry inertSpecie $arg \ + constant/thermophysicalProperties.$phase } setThermoAndEnergy() @@ -32,7 +33,7 @@ setThermoAndEnergy() * ) exit 1;; esac - foamDictionary -entry thermoType.thermo -set $thermo \ + runApplication -a foamDictionary -entry thermoType.thermo -set $thermo \ constant/thermophysicalProperties.$phase case $he in @@ -41,7 +42,7 @@ setThermoAndEnergy() * ) exit 1;; esac - foamDictionary -entry thermoType.energy -set $energy \ + runApplication -a foamDictionary -entry thermoType.energy -set $energy \ constant/thermophysicalProperties.$phase } diff --git a/test/multiphase/multiphaseEulerFoam/thermal/waterEvaporation/Allrun b/test/multiphase/multiphaseEulerFoam/thermal/waterEvaporation/Allrun index 4ba94f1d2b..5ed2a869be 100755 --- a/test/multiphase/multiphaseEulerFoam/thermal/waterEvaporation/Allrun +++ b/test/multiphase/multiphaseEulerFoam/thermal/waterEvaporation/Allrun @@ -12,7 +12,7 @@ setThermoAndEnergy() he=${1%.*} phase=${1#*.} - foamDictionary -entry thermoType.thermo -set ${he}Const \ + runApplication -a foamDictionary -entry thermoType.thermo -set ${he}Const \ constant/thermophysicalProperties.$phase case $he in @@ -21,7 +21,7 @@ setThermoAndEnergy() * ) exit 1;; esac - foamDictionary -entry thermoType.energy -set $energy \ + runApplication -a foamDictionary -entry thermoType.energy -set $energy \ constant/thermophysicalProperties.$phase } diff --git a/tutorials/Allrun b/tutorials/Allrun index 0b5a7f92b9..8bd667576e 100755 --- a/tutorials/Allrun +++ b/tutorials/Allrun @@ -3,7 +3,7 @@ # ========= | # \\ / F ield | OpenFOAM: The Open Source CFD Toolbox # \\ / O peration | Website: https://openfoam.org -# \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation +# \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation # \\/ M anipulation | #------------------------------------------------------------------------------ # License @@ -80,7 +80,7 @@ logReportDir() cd $1 || return 1 - logs=`find . -name "log.*"` + logs=`find . -name "log.*" ! -name "log.foamDictionary"` [ -n "$logs" ] || return 0 retVal=0 diff --git a/tutorials/combustion/XiFoam/RAS/Allrun b/tutorials/combustion/XiFoam/RAS/Allrun index d06d947b1f..645620f005 100755 --- a/tutorials/combustion/XiFoam/RAS/Allrun +++ b/tutorials/combustion/XiFoam/RAS/Allrun @@ -28,9 +28,9 @@ cloneCase moriyoshiHomogeneous moriyoshiHomogeneousHydrogen if ! isTest $@ then - foamDictionary system/controlDict -entry deltaT -set 1e-05 - foamDictionary system/controlDict -entry endTime -set 0.015 - foamDictionary system/controlDict -entry writeInterval -set 50 + runApplication -a foamDictionary system/controlDict -entry deltaT -set 1e-05 + runApplication -a foamDictionary system/controlDict -entry endTime -set 0.015 + runApplication -a foamDictionary system/controlDict -entry writeInterval -set 50 runApplication -a XiFoam fi diff --git a/tutorials/combustion/reactingFoam/RAS/SandiaD_LTS/Allrun b/tutorials/combustion/reactingFoam/RAS/SandiaD_LTS/Allrun index cc16b197b6..d0c44628b8 100755 --- a/tutorials/combustion/reactingFoam/RAS/SandiaD_LTS/Allrun +++ b/tutorials/combustion/reactingFoam/RAS/SandiaD_LTS/Allrun @@ -17,20 +17,20 @@ runApplication setFields if ! isTest $@ then # Run the application without chemistry until 1500 to let the flow develop - foamDictionary -entry "startTime" -set "0" system/controlDict - foamDictionary -entry "writeInterval" -set "1500" system/controlDict - foamDictionary -entry "endTime" -set "1500" system/controlDict + runApplication -a foamDictionary -entry "startTime" -set "0" system/controlDict + runApplication -a foamDictionary -entry "writeInterval" -set "1500" system/controlDict + runApplication -a foamDictionary -entry "endTime" -set "1500" system/controlDict rm -rf constant/chemistryProperties > /dev/null 2>&1 - foamDictionary -entry "chemistry" -set "off" constant/chemistryProperties + runApplication -a foamDictionary -entry "chemistry" -set "off" constant/chemistryProperties runApplication $application # Run with chemistry until flame reach its full size - foamDictionary -entry "startTime" -set "1500" system/controlDict - foamDictionary -entry "writeInterval" -set "100" system/controlDict - foamDictionary -entry "endTime" -set "5000" system/controlDict + runApplication -a foamDictionary -entry "startTime" -set "1500" system/controlDict + runApplication -a foamDictionary -entry "writeInterval" -set "100" system/controlDict + runApplication -a foamDictionary -entry "endTime" -set "5000" system/controlDict rm -rf constant/chemistryProperties > /dev/null 2>&1 - foamDictionary -entry "chemistry" -set "on" constant/chemistryProperties + runApplication -a foamDictionary -entry "chemistry" -set "on" constant/chemistryProperties fi runApplication -o $application diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/coolingSphere/Allrun b/tutorials/heatTransfer/chtMultiRegionFoam/coolingSphere/Allrun index 0dd57558ab..cf62438f0d 100755 --- a/tutorials/heatTransfer/chtMultiRegionFoam/coolingSphere/Allrun +++ b/tutorials/heatTransfer/chtMultiRegionFoam/coolingSphere/Allrun @@ -8,7 +8,7 @@ cd ${0%/*} || exit 1 # Run from this directory runApplication foamSetupCHT -foamDictionary -entry internalField -set "uniform 348" 0/solid/T +runApplication foamDictionary -entry internalField -set "uniform 348" 0/solid/T runApplication decomposePar -allRegions -dict system/decomposeParDict diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/shellAndTubeHeatExchanger/Allmesh.layers b/tutorials/heatTransfer/chtMultiRegionFoam/shellAndTubeHeatExchanger/Allmesh.layers index 019d0bfc6e..9c9a04ee3f 100755 --- a/tutorials/heatTransfer/chtMultiRegionFoam/shellAndTubeHeatExchanger/Allmesh.layers +++ b/tutorials/heatTransfer/chtMultiRegionFoam/shellAndTubeHeatExchanger/Allmesh.layers @@ -9,9 +9,9 @@ runApplication blockMesh runApplication decomposePar -copyZero # Run snappy without layers -foamDictionary system/snappyHexMeshDict -entry castellatedMesh -set on -foamDictionary system/snappyHexMeshDict -entry snap -set on -foamDictionary system/snappyHexMeshDict -entry addLayers -set off +runApplication -a foamDictionary system/snappyHexMeshDict -entry castellatedMesh -set on +runApplication -a foamDictionary system/snappyHexMeshDict -entry snap -set on +runApplication -a foamDictionary system/snappyHexMeshDict -entry addLayers -set off runParallel snappyHexMesh -overwrite # Convert the face zones into mapped wall baffles and split @@ -20,9 +20,9 @@ runParallel mergeOrSplitBaffles -split -overwrite rm -rf processor*/constant/polyMesh/pointLevel # Run snappy again to create layers -foamDictionary system/snappyHexMeshDict -entry castellatedMesh -set off -foamDictionary system/snappyHexMeshDict -entry snap -set off -foamDictionary system/snappyHexMeshDict -entry addLayers -set on +runApplication -a foamDictionary system/snappyHexMeshDict -entry castellatedMesh -set off +runApplication -a foamDictionary system/snappyHexMeshDict -entry snap -set off +runApplication -a foamDictionary system/snappyHexMeshDict -entry addLayers -set on runParallel -a snappyHexMesh -overwrite # Split the mesh into regions diff --git a/tutorials/incompressible/pimpleFoam/RAS/flowWithOpenBoundary/Allrun b/tutorials/incompressible/pimpleFoam/RAS/flowWithOpenBoundary/Allrun index 3b30eafc38..8eac2fcdd1 100755 --- a/tutorials/incompressible/pimpleFoam/RAS/flowWithOpenBoundary/Allrun +++ b/tutorials/incompressible/pimpleFoam/RAS/flowWithOpenBoundary/Allrun @@ -36,7 +36,7 @@ setAtmosphereBC () { echo "Setting $_field BC on atmosphere patch to $_BC" - foamDictionary \ + runApplication -a foamDictionary \ -entry boundaryField.atmosphere.type \ -set "$_BC" \ "0/$_field" > /dev/null 2>&1 diff --git a/tutorials/incompressible/simpleFoam/turbineSiting/Allrun b/tutorials/incompressible/simpleFoam/turbineSiting/Allrun index 00da955932..af9ca8ea03 100755 --- a/tutorials/incompressible/simpleFoam/turbineSiting/Allrun +++ b/tutorials/incompressible/simpleFoam/turbineSiting/Allrun @@ -5,9 +5,9 @@ cd ${0%/*} || exit 1 # Run from this directory . $WM_PROJECT_DIR/bin/tools/RunFunctions runApplication blockMesh -foamDictionary -entry "method" -set "hierarchical" system/decomposeParDict +runApplication -a foamDictionary -entry "method" -set "hierarchical" system/decomposeParDict runApplication decomposePar -copyZero -foamDictionary -entry "method" -set "ptscotch" system/decomposeParDict +runApplication -a foamDictionary -entry "method" -set "ptscotch" system/decomposeParDict runParallel snappyHexMesh -overwrite runParallel topoSet diff --git a/tutorials/multiphase/interFoam/RAS/DTCHull/Allmesh b/tutorials/multiphase/interFoam/RAS/DTCHull/Allmesh index d1b0eb5267..abdeb34ed2 100755 --- a/tutorials/multiphase/interFoam/RAS/DTCHull/Allmesh +++ b/tutorials/multiphase/interFoam/RAS/DTCHull/Allmesh @@ -13,7 +13,7 @@ runApplication blockMesh for i in 1 2 3 4 5 6 do - foamDictionary system/refineMeshDict -entry set -set c${i} + runApplication -a foamDictionary system/refineMeshDict -entry set -set c${i} runApplication -a topoSet diff --git a/tutorials/multiphase/interFoam/RAS/DTCHullMoving/Allmesh b/tutorials/multiphase/interFoam/RAS/DTCHullMoving/Allmesh index d1b0eb5267..abdeb34ed2 100755 --- a/tutorials/multiphase/interFoam/RAS/DTCHullMoving/Allmesh +++ b/tutorials/multiphase/interFoam/RAS/DTCHullMoving/Allmesh @@ -13,7 +13,7 @@ runApplication blockMesh for i in 1 2 3 4 5 6 do - foamDictionary system/refineMeshDict -entry set -set c${i} + runApplication -a foamDictionary system/refineMeshDict -entry set -set c${i} runApplication -a topoSet diff --git a/tutorials/multiphase/interFoam/RAS/DTCHullWave/Allmesh b/tutorials/multiphase/interFoam/RAS/DTCHullWave/Allmesh index d1b0eb5267..abdeb34ed2 100755 --- a/tutorials/multiphase/interFoam/RAS/DTCHullWave/Allmesh +++ b/tutorials/multiphase/interFoam/RAS/DTCHullWave/Allmesh @@ -13,7 +13,7 @@ runApplication blockMesh for i in 1 2 3 4 5 6 do - foamDictionary system/refineMeshDict -entry set -set c${i} + runApplication -a foamDictionary system/refineMeshDict -entry set -set c${i} runApplication -a topoSet diff --git a/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.1 b/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.1 index cf47dfd79f..efde54c0ae 100755 --- a/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.1 +++ b/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.1 @@ -17,7 +17,7 @@ runApplication blockMesh -dict system/blockMeshDict.1 for i in 1 2 3 4 5 6 7 do - foamDictionary system/refineMeshDict -entry set -set c${i} + runApplication -a foamDictionary system/refineMeshDict -entry set -set c${i} runApplication -a topoSet -dict system/topoSetDict.1 runApplication -a refineMesh -dict system/refineMeshDict -overwrite done diff --git a/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.2 b/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.2 index e3a52317bd..2dbf15e8a9 100755 --- a/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.2 +++ b/tutorials/multiphase/interFoam/RAS/planingHullW3/Allmesh.2 @@ -17,7 +17,7 @@ runApplication blockMesh -dict system/blockMeshDict.2 for i in 1 2 3 4 do - foamDictionary system/refineMeshDict -entry set -set c${i} + runApplication -a foamDictionary system/refineMeshDict -entry set -set c${i} runApplication -a topoSet -dict system/topoSetDict.2 runApplication -a refineMesh -dict system/refineMeshDict -overwrite done diff --git a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoiling/Allrun b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoiling/Allrun index 3c7d8581f5..1ab57085dd 100755 --- a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoiling/Allrun +++ b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoiling/Allrun @@ -14,8 +14,8 @@ runParallel $application if ! isTest $@ then - foamDictionary system/controlDict -entry endTime -set 4 - foamDictionary system/controlDict -entry startTime -set 0.5 + runApplication -a foamDictionary system/controlDict -entry endTime -set 4 + runApplication -a foamDictionary system/controlDict -entry startTime -set 0.5 runParallel -a foamDictionary 0.5/T.liquid -entry boundaryField.wall.q -set "uniform 73900" runParallel -a foamDictionary 0.5/U.liquid -entry boundaryField.inlet.type -set "fixedValue" runParallel -a $application diff --git a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingIATE/Allrun b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingIATE/Allrun index 3c7d8581f5..1ab57085dd 100755 --- a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingIATE/Allrun +++ b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingIATE/Allrun @@ -14,8 +14,8 @@ runParallel $application if ! isTest $@ then - foamDictionary system/controlDict -entry endTime -set 4 - foamDictionary system/controlDict -entry startTime -set 0.5 + runApplication -a foamDictionary system/controlDict -entry endTime -set 4 + runApplication -a foamDictionary system/controlDict -entry startTime -set 0.5 runParallel -a foamDictionary 0.5/T.liquid -entry boundaryField.wall.q -set "uniform 73900" runParallel -a foamDictionary 0.5/U.liquid -entry boundaryField.inlet.type -set "fixedValue" runParallel -a $application diff --git a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperse/Allrun b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperse/Allrun index 249e8003dc..5a1b4995c0 100755 --- a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperse/Allrun +++ b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperse/Allrun @@ -15,8 +15,8 @@ runParallel $application if ! isTest $@ then - foamDictionary system/controlDict -entry endTime -set 4 - foamDictionary system/controlDict -entry startTime -set 0.5 + runApplication -a foamDictionary system/controlDict -entry endTime -set 4 + runApplication -a foamDictionary system/controlDict -entry startTime -set 0.5 runParallel -a foamDictionary -expand 0.5/T.liquid -entry boundaryField.wall.q -set "uniform 73900" runParallel -a foamDictionary -expand 0.5/U.liquid -entry boundaryField.inlet.type -set "fixedValue" runParallel -a $application diff --git a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperseTwoGroups/Allrun b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperseTwoGroups/Allrun index 249e8003dc..5a1b4995c0 100755 --- a/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperseTwoGroups/Allrun +++ b/tutorials/multiphase/multiphaseEulerFoam/RAS/wallBoilingPolydisperseTwoGroups/Allrun @@ -15,8 +15,8 @@ runParallel $application if ! isTest $@ then - foamDictionary system/controlDict -entry endTime -set 4 - foamDictionary system/controlDict -entry startTime -set 0.5 + runApplication -a foamDictionary system/controlDict -entry endTime -set 4 + runApplication -a foamDictionary system/controlDict -entry startTime -set 0.5 runParallel -a foamDictionary -expand 0.5/T.liquid -entry boundaryField.wall.q -set "uniform 73900" runParallel -a foamDictionary -expand 0.5/U.liquid -entry boundaryField.inlet.type -set "fixedValue" runParallel -a $application