@@ -5,7 +5,11 @@ def mysqlVersion = "5.5"
55def launchUnitTests = " yes"
66def launchIntegrationTests = " yes"
77def launchBehatTests = " yes"
8- def commit = " ${ env.GIT_COMMIT} "
8+
9+ class Globals {
10+ static pimVersion = " 1.7"
11+ static extensionBranch = " dev-master"
12+ }
913
1014stage(" Checkout" ) {
1115 milestone 1
@@ -26,13 +30,13 @@ stage("Checkout") {
2630 stash " excel_init"
2731
2832 checkout([$class : ' GitSCM' ,
29- branches : [[name : ' 1.7 ' ]],
33+ branches : [[name : " ${ Globals.pimVersion } " ]],
3034 userRemoteConfigs : [[credentialsId : ' github-credentials' , url : ' https://github.com/akeneo/pim-community-standard.git' ]]
3135 ])
3236 stash " pim_community"
3337
3438 checkout([$class : ' GitSCM' ,
35- branches : [[name : ' 1.7 ' ]],
39+ branches : [[name : " ${ Globals.pimVersion } " ]],
3640 userRemoteConfigs : [[credentialsId : ' github-credentials' , url : ' https://github.com/akeneo/pim-enterprise-standard.git' ]]
3741 ])
3842 stash " pim_enterprise"
@@ -44,11 +48,9 @@ if (launchUnitTests.equals("yes")) {
4448 def tasks = [:]
4549
4650 tasks[" phpspec-5.6" ] = {runPhpSpecTest(" 5.6" )}
47- tasks[" phpspec-7.0" ] = {runPhpSpecTest(" 7.0" )}
4851 tasks[" phpspec-7.1" ] = {runPhpSpecTest(" 7.1" )}
4952
5053 tasks[" php-cs-fixer-5.6" ] = {runPhpCsFixerTest(" 5.6" )}
51- tasks[" php-cs-fixer-7.0" ] = {runPhpCsFixerTest(" 7.0" )}
5254 tasks[" php-cs-fixer-7.1" ] = {runPhpCsFixerTest(" 7.1" )}
5355
5456 parallel tasks
@@ -60,10 +62,10 @@ if (launchIntegrationTests.equals("yes")) {
6062 def tasks = [:]
6163
6264 tasks[" phpunit-5.6-ce" ] = {runIntegrationTest(" 5.6" )}
63- tasks[" phpunit-7.0 -ce" ] = {runIntegrationTest(" 7.0 " )}
65+ tasks[" phpunit-7.1 -ce" ] = {runIntegrationTest(" 7.1 " )}
6466
6567 tasks[" phpunit-5.6-ee" ] = {runIntegrationTestEE(" 5.6" )}
66- tasks[" phpunit-7.0 -ee" ] = {runIntegrationTestEE(" 7.0 " )}
68+ tasks[" phpunit-7.1 -ee" ] = {runIntegrationTestEE(" 7.1 " )}
6769
6870 parallel tasks
6971 }
@@ -118,10 +120,11 @@ def runIntegrationTest(version) {
118120 sh " composer require --no-update alcaeus/mongo-php-adapter"
119121 }
120122
121- sh " composer require --no-update phpunit/phpunit akeneo/excel-init-bundle"
123+ sh " composer require --no-update phpunit/phpunit akeneo/excel-init-bundle: ${ Globals.extensionBranch } "
122124 sh " composer update --ignore-platform-reqs --optimize-autoloader --no-interaction --no-progress --prefer-dist"
123125
124126 dir(" vendor/akeneo/excel-init-bundle" ) {
127+ deleteDir()
125128 unstash " excel_init"
126129 }
127130 sh " composer dump-autoload -o"
@@ -149,7 +152,7 @@ def runIntegrationTestEE(version) {
149152 sh " composer require --no-update alcaeus/mongo-php-adapter"
150153 }
151154
152- sh " composer require --no-update phpunit/phpunit akeneo/excel-init-bundle"
155+ sh " composer require --no-update phpunit/phpunit akeneo/excel-init-bundle: ${ Globals.extensionBranch } "
153156 sh " composer update --ignore-platform-reqs --optimize-autoloader --no-interaction --no-progress --prefer-dist"
154157
155158 dir(" vendor/akeneo/excel-init-bundle" ) {
0 commit comments