Last active
September 5, 2018 15:04
-
-
Save alexwoollam/f850ad71a5bb33f207bad98161f2be1d to your computer and use it in GitHub Desktop.
Jenkinsfile for wordpress wip
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
pipeline { | |
agent any | |
stages { | |
stage('Checkout Repo') { | |
steps { | |
checkout scm | |
} | |
} | |
stage('Build') { | |
steps { | |
sh 'chmod --recursive a+rwx ./bin/install-wp-tests.sh' | |
sh './bin/install-wp-tests.sh wordpress wordpress wordpress 127.0.0.1 4.9.8 false' | |
} | |
} | |
stage('Test') { | |
steps { | |
sh 'chmod --recursive a+rwx ./bin/do-tests.sh' | |
sh './bin/do-tests.sh' | |
} | |
} | |
} | |
post { | |
success { | |
echo 'For the win!' | |
} | |
failure { | |
echo 'Epic Fail!' | |
} | |
always{ | |
sh 'mysql -uwordpress -pwordpress -e "DROP DATABASE IF EXISTS wordpress"' | |
deleteDir() | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment