opm-simulators/tests/run-test.sh
Arne Morten Kvarving e5b32dd82d add norne and norne_parallel as ExtraTests
to execute these you have to use ctest -C ExtraTests
or 'make extra_test'
2020-04-14 16:02:21 +02:00

22 lines
406 B
Bash
Executable File

#!/bin/bash
# This simply runs a simulator.
INPUT_DATA_PATH="$1"
RESULT_PATH="$2"
BINPATH="$3"
EXE_NAME="$4"
FILENAME="$5"
MPI_PROCS="$6"
shift 7
TEST_ARGS="$@"
mkdir -p ${RESULT_PATH}
if (( ${MPI_PROCS} > 1))
then
mpirun -np ${MPI_PROCS} ${BINPATH}/${EXE_NAME} ${TEST_ARGS} --output-dir=${RESULT_PATH}
else
${BINPATH}/${EXE_NAME} ${TEST_ARGS} --output-dir=${RESULT_PATH}
fi
test $? -eq 0 || exit 1