Skip to content

Commit 9384262

Browse files
authored
Merge pull request #1810 from EOSIO/mongo-tests-jenkins
Mongo tests jenkins
2 parents a7f2601 + 906a0ee commit 9384262

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

Jenkinsfile

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ pipeline {
4343
unstash 'buildUbuntu'
4444
sh '''
4545
. $HOME/.bash_profile
46+
if ! /usr/bin/pgrep mongod &>/dev/null; then
47+
/usr/bin/mongod -f /etc/mongod.conf > /dev/null 2>&1 &
48+
fi
4649
cd build
4750
printf "Waiting for testing to be available..."
4851
while /usr/bin/pgrep -x ctest > /dev/null; do sleep 1; done
@@ -65,10 +68,10 @@ pipeline {
6568
unstash 'buildMacOS'
6669
sh '''
6770
. $HOME/.bash_profile
71+
if ! /usr/bin/pgrep mongod &>/dev/null; then
72+
/usr/local/bin/mongod -f /usr/local/etc/mongod.conf > /dev/null 2>&1 &
73+
fi
6874
cd build
69-
printf "Waiting for testing to be available..."
70-
while /usr/bin/pgrep -x ctest > /dev/null; do sleep 1; done
71-
echo "OK!"
7275
ctest --output-on-failure
7376
'''
7477
}
@@ -87,6 +90,9 @@ pipeline {
8790
unstash 'buildFedora'
8891
sh '''
8992
. $HOME/.bash_profile
93+
if ! /usr/bin/pgrep mongod &>/dev/null; then
94+
/usr/bin/mongod -f /etc/mongod.conf > /dev/null 2>&1 &
95+
fi
9096
cd build
9197
printf "Waiting for testing to be available..."
9298
while /usr/bin/pgrep -x ctest > /dev/null; do sleep 1; done

0 commit comments

Comments
 (0)