Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nek5000
giraffe
Commits
fd3a5de9
Commit
fd3a5de9
authored
Oct 09, 2017
by
Ron Rahaman
Browse files
Added MPI CI tests
parent
1f283676
Pipeline
#2771
failed with stages
in 102 minutes and 27 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
fd3a5de9
stages
:
-
build_libmesh_stage
-
configure_giraffe_stage
-
build_giraffe_stage
-
run_giraffe_stage
-
verify_giraffe_stage
-
build_libmesh
-
configure_giraffe
-
build_giraffe
-
run_giraffe_serial
-
verify_giraffe_serial
-
run_giraffe_parallel
-
verify_giraffe_parallel
before_script
:
-
. /opt/moose/environments/moose_profile
build_libmesh
:
stage
:
build_libmesh
_stage
build_libmesh
_job
:
stage
:
build_libmesh
script
:
-
pwd
-
git clone -b master https://github.com/idaholab/moose.git
-
cd moose
-
scripts/update_and_rebuild_libmesh.sh
configure_giraffe
:
stage
:
configure_giraffe
_stage
configure_giraffe
_job
:
stage
:
configure_giraffe
dependencies
:
-
build_libmesh
-
build_libmesh
_job
variables
:
GIT_STRATEGY
:
none
MOOSE_DIR
:
"
$CI_PROJECT_DIR/moose"
...
...
@@ -29,10 +31,10 @@ configure_giraffe:
-
cd examples/integration_example/
-
../../configure
build_giraffe
:
stage
:
build_giraffe
_stage
build_giraffe
_job
:
stage
:
build_giraffe
dependencies
:
-
configure_giraffe
-
configure_giraffe
_job
variables
:
GIT_STRATEGY
:
none
MOOSE_DIR
:
"
$CI_PROJECT_DIR/moose"
...
...
@@ -41,10 +43,10 @@ build_giraffe:
-
cd examples/integration_example/
-
make -j8
run_giraffe
:
stage
:
run_giraffe_s
tage
run_giraffe
_serial_job
:
stage
:
run_giraffe_s
erial
dependencies
:
-
build_giraffe
-
build_giraffe
_job
variables
:
GIT_STRATEGY
:
none
MOOSE_DIR
:
"
$CI_PROJECT_DIR/moose"
...
...
@@ -52,19 +54,52 @@ run_giraffe:
script
:
-
set -o pipefail
-
cd examples/integration_example
-
../../giraffe-opt -i coefficient_integration.i | tee integration_example.stdout
-
../../giraffe-opt -i coefficient_integration.i | tee integration_example
_serial
.stdout
-
exit $?
verify_giraffe
:
stage
:
verify_giraffe_s
tage
verify_giraffe
_serial_job
:
stage
:
verify_giraffe_s
erial
dependencies
:
-
run_giraffe
-
run_giraffe
_serial_job
variables
:
GIT_STRATEGY
:
none
script
:
-
cd examples/integration_example
-
v1=$(grep "Heat balance" integration_example.stdout | tail -1 | tr -s ' ' | cut -d ' ' -f 5)
-
v2=$(grep "Heat balance" integration_example.stdout | tail -1 | tr -s ' ' | cut -d ' ' -f 6)
-
grep -n "Heat balance" integration_example_serial.stdout
-
v1=$(grep "Heat balance" integration_example_serial.stdout | tail -1 | tr -s ' ' | cut -d ' ' -f 5)
-
v2=$(grep "Heat balance" integration_example_serial.stdout | tail -1 | tr -s ' ' | cut -d ' ' -f 6)
# We want to test this statement:
# (0.78529 < $v1 < 0.78549) && (0.78203 < $v2 < 0.78203)
# However, bc will return 1 if true, and we want the script to return 0 if successful
# Hence, we test the inverse of that statement. The inverse statement will
# return 0 if the *desired* condition is true.
-
echo "$v1 < 0.78529825617157133 || $v1 > 0.78549825617157133 || $v2 < 0.78203376069904283 || $v2 > 0.78223376069904283" | bc
run_giraffe_parallel_job
:
stage
:
run_giraffe_parallel
dependencies
:
-
build_giraffe_job
variables
:
GIT_STRATEGY
:
none
MOOSE_DIR
:
"
$CI_PROJECT_DIR/moose"
LIBMESH_DIR
:
"
$CI_PROJECT_DIR/moose/libmesh/installed"
script
:
-
set -o pipefail
-
cd examples/integration_example
-
mpirun -np 4 ../../giraffe-opt -i coefficient_integration.i | tee integration_example_parallel.stdout
-
exit $?
verify_giraffe_parallel_job
:
stage
:
verify_giraffe_parallel
dependencies
:
-
run_giraffe_parallel_job
variables
:
GIT_STRATEGY
:
none
script
:
-
cd examples/integration_example
-
grep -n "Heat balance" integration_example_parallel.stdout
-
v1=$(grep "Heat balance" integration_example_parallel.stdout | tail -1 | tr -s ' ' | cut -d ' ' -f 5)
-
v2=$(grep "Heat balance" integration_example_parallel.stdout | tail -1 | tr -s ' ' | cut -d ' ' -f 6)
# We want to test this statement:
# (0.78529 < $v1 < 0.78549) && (0.78203 < $v2 < 0.78203)
# However, bc will return 1 if true, and we want the script to return 0 if successful
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment