Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
sds
mobject-store
Commits
106bd3b1
Commit
106bd3b1
authored
Nov 01, 2017
by
Shane Snyder
Browse files
test utilities for mobject
parent
9d4ed679
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/mobject-test-util.sh
0 → 100755
View file @
106bd3b1
#
# General test script utilities
#
if
[
-z
"
$TIMEOUT
"
]
;
then
echo
expected TIMEOUT variable defined to its respective
command
exit
1
fi
function
run_to
()
{
maxtime
=
${
1
}
s
shift
$TIMEOUT
--signal
=
9
$maxtime
"
$@
"
}
function
mobject_test_start_servers
()
{
nservers
=
${
1
:-
4
}
startwait
=
${
2
:-
15
}
maxtime
=
${
3
:-
120
}
cfile
=
${
4
:-
/tmp/mobject-connect-cluster.gid
}
run_to
$maxtime
mpirun
-np
$nservers
src/server/mobject-server-daemon na+sm://
$cfile
&
if
[
$?
-ne
0
]
;
then
# TODO: this doesn't actually work; can't check return code of
# something executing in background. We have to rely on the
# return codes of the actual client side tests to tell if
# everything started properly
exit
1
fi
# wait for servers to start
sleep
${
startwait
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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