@@ -83,23 +83,49 @@ pipeline {
8383 '''
8484 }
8585 }
86- stage(' Test ' ) {
86+ stage(' Integration Tests Sqlite ' ) {
8787 steps {
8888 // Bring up a stack
89- sh ' docker-compose up -d fullstack'
90- sh ' ./scripts/wait-healthy $(docker-compose ps -q fullstack) 120'
89+ sh ' docker-compose up -d fullstack-sqlite '
90+ sh ' ./scripts/wait-healthy $(docker-compose ps -q fullstack-sqlite ) 120'
9191
9292 // Run tests
9393 sh ' rm -rf test/results'
94- sh ' docker-compose up cypress'
94+ sh ' docker-compose up cypress-sqlite '
9595 // Get results
96- sh ' docker cp -L "$(docker-compose ps -q cypress): /results" test/'
96+ sh ' docker cp -L "$(docker-compose ps -q cypress-sqlite):/test /results" test/'
9797 }
9898 post {
9999 always {
100100 // Dumps to analyze later
101101 sh ' mkdir -p debug'
102- sh ' docker-compose logs fullstack | gzip > debug/docker_fullstack.log.gz'
102+ sh ' docker-compose logs fullstack-sqlite | gzip > debug/docker_fullstack_sqlite.log.gz'
103+ sh ' docker-compose logs db | gzip > debug/docker_db.log.gz'
104+ // Cypress videos and screenshot artifacts
105+ dir(path : ' test/results' ) {
106+ archiveArtifacts allowEmptyArchive : true , artifacts : ' **/*' , excludes : ' **/*.xml'
107+ }
108+ junit ' test/results/junit/*'
109+ }
110+ }
111+ }
112+ stage(' Integration Tests Mysql' ) {
113+ steps {
114+ // Bring up a stack
115+ sh ' docker-compose up -d fullstack-mysql'
116+ sh ' ./scripts/wait-healthy $(docker-compose ps -q fullstack-mysql) 120'
117+
118+ // Run tests
119+ sh ' rm -rf test/results'
120+ sh ' docker-compose up cypress-mysql'
121+ // Get results
122+ sh ' docker cp -L "$(docker-compose ps -q cypress-mysql):/test/results" test/'
123+ }
124+ post {
125+ always {
126+ // Dumps to analyze later
127+ sh ' mkdir -p debug'
128+ sh ' docker-compose logs fullstack-mysql | gzip > debug/docker_fullstack_mysql.log.gz'
103129 sh ' docker-compose logs db | gzip > debug/docker_db.log.gz'
104130 // Cypress videos and screenshot artifacts
105131 dir(path : ' test/results' ) {
@@ -136,8 +162,9 @@ pipeline {
136162 }
137163 steps {
138164 withCredentials([usernamePassword(credentialsId : ' jc21-dockerhub' , passwordVariable : ' dpass' , usernameVariable : ' duser' )]) {
165+ // Docker Login
139166 sh " docker login -u '${ duser} ' -p '${ dpass} '"
140- // Buildx with push
167+ // Buildx with push from cache
141168 sh " ./scripts/buildx --push ${ BUILDX_PUSH_TAGS} "
142169 }
143170 }
0 commit comments