File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33# VERSION: Major.Minor python version.
44# WEBFRAMEWORK: What framework to be tested. String format.
55# ASYNCIO: Whether it's enabled or disabled. Boolean format.
6- # DISTUTILS_USE_SDK: Whether configuring the environment to build with MSVC on a 64bit architecture. Binary format.
76#
87
98windows :
10- - VERSION : " 3.5 "
9+ - VERSION : " 2.7 "
1110 WEBFRAMEWORK : " none"
1211 ASYNCIO : " false"
13- DISTUTILS_USE_SDK : " 0"
1412 - VERSION : " 3.5"
1513 WEBFRAMEWORK : " none"
1614 ASYNCIO : " false"
17- DISTUTILS_USE_SDK : " 1"
1815 - VERSION : " 3.6"
1916 WEBFRAMEWORK : " none"
2017 ASYNCIO : " true"
21- DISTUTILS_USE_SDK : " 0"
2218 - VERSION : " 3.7"
2319 WEBFRAMEWORK : " none"
2420 ASYNCIO : " true"
25- DISTUTILS_USE_SDK : " 0"
2621 - VERSION : " 3.8"
2722 WEBFRAMEWORK : " none"
2823 ASYNCIO : " true"
29- DISTUTILS_USE_SDK : " 0"
Original file line number Diff line number Diff line change @@ -117,7 +117,7 @@ pipeline {
117117
118118 // Let's now enable the windows stages
119119 readYaml(file : ' .ci/.jenkins_windows.yml' )[' windows' ]. each { v ->
120- def description = " ${ v.VERSION}${ v.DISTUTILS_USE_SDK.equals('1') ? '-sdk' : '' } -${ v.WEBFRAMEWORK} "
120+ def description = " ${ v.VERSION} -${ v.WEBFRAMEWORK} "
121121 mapParallelTasks[" windows-${ description} " ] = generateStepForWindows(v)
122122 }
123123 parallel(mapParallelTasks)
@@ -421,7 +421,7 @@ def releasePackages(){
421421
422422def generateStepForWindows (Map v = [:]){
423423 return {
424- log(level : ' INFO' , text : " version=${ v.VERSION} distutils= ${ v.DISTUTILS_USE_SDK } framework=${ v.WEBFRAMEWORK} asyncio=${ v.ASYNCIO} " )
424+ log(level : ' INFO' , text : " version=${ v.VERSION} framework=${ v.WEBFRAMEWORK} asyncio=${ v.ASYNCIO} " )
425425 // Python installations with choco in Windows do follow the pattern:
426426 // C:\Python<Major><Minor>, for instance: C:\Python27
427427 def pythonPath = " C:\\ Python${ v.VERSION.replaceAll('\\.', '')} "
@@ -430,7 +430,6 @@ def generateStepForWindows(Map v = [:]){
430430 node(' windows-2019-docker-immutable' ){
431431 withEnv([" VERSION=${ v.VERSION} " ,
432432 " PYTHON=${ pythonPath} " ,
433- " DISTUTILS_USE_SDK=${ v.DISTUTILS_USE_SDK} " ,
434433 " ASYNCIO=${ v.ASYNCIO} " ,
435434 " WEBFRAMEWORK=${ v.WEBFRAMEWORK} " ]) {
436435 try {
Original file line number Diff line number Diff line change 11: Required tools before running the tests in windows.
22: It does require the below list of environment variables:
3- : - DISTUTILS_USE_SDK: optional
43: - PYTHON: the python installation path.
54: - WEBFRAMEWORK: the framework to be installed.
65@ echo off
76
8- IF " %DISTUTILS_USE_SDK% " == " 1" (
9- : See https://devblogs.microsoft.com/python/unable-to-find-vcvarsall-bat/
10- ECHO Install dependencies
11- choco install windows-sdk-7.1 -y --no-progress -r
12- call " C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /x64
13- ) ELSE (
14- ECHO Setup local installation
15- : See https://stackoverflow.com/a/43570522
16- call " C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\vsdevcmd.bat" -arch=amd64
17- )
7+ : Prepare the env context
8+ call " C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\vsdevcmd.bat" -arch=amd64
189
1910: We need wheel installed to build wheels
20- call .\tests\appveyor\build.cmd %PYTHON% \python.exe -m pip install -U wheel pip setuptools
21- call .\tests\appveyor\build.cmd %PYTHON% \python.exe -m pip install -r tests\requirements\requirements-%WEBFRAMEWORK% .txt
22- call .\tests\appveyor\build.cmd %PYTHON% \python.exe -m pip install psutil
11+ call %PYTHON% \python.exe -m pip install -U wheel pip setuptools
12+ call %PYTHON% \python.exe -m pip install -r tests\requirements\requirements-%WEBFRAMEWORK% .txt
13+ call %PYTHON% \python.exe -m pip install psutil
Original file line number Diff line number Diff line change 11: Run the tests in Windows
22: It does require the below list of environment variables:
3+ : - VERSION: the python version.
34: - ASYNCIO: if asyncio is enabled or not.
45: - PYTHON: the python installation path.
56@ echo off
@@ -9,7 +10,15 @@ call .\tests\scripts\download_json_schema.bat
910ECHO Download gherkin feature dependencies
1011call .\tests\scripts\download_gherkin_features.bat
1112
13+ @ echo on
14+ set IGNORE_PYTHON3_WITH_PYTHON2 =
15+ if " %VERSION% " == " 2.7" set IGNORE_PYTHON3_WITH_PYTHON2 = --ignore-glob=" *\py3_*.py"
16+
1217set PYTEST_JUNIT = " --junitxml=.\tests\python-agent-junit.xml"
13- if " %ASYNCIO% " == " true" call .\tests\appveyor\build.cmd %PYTHON% \python.exe -m pytest %PYTEST_JUNIT% -m " not integrationtest"
14- if " %ASYNCIO% " == " false" call .\tests\appveyor\build.cmd %PYTHON% \python.exe -m pytest %PYTEST_JUNIT% --ignore-glob=" */asyncio/*" -m " not integrationtest"
15- call .\tests\appveyor\build.cmd %PYTHON% \python.exe setup.py bdist_wheel
18+ if " %ASYNCIO% " == " true" (
19+ call %PYTHON% \python.exe -m pytest %PYTEST_JUNIT% %IGNORE_PYTHON3_WITH_PYTHON2% -m " not integrationtest"
20+ )
21+ if " %ASYNCIO% " == " false" (
22+ call %PYTHON% \python.exe -m pytest %PYTEST_JUNIT% --ignore-glob=" *\asyncio\*" %IGNORE_PYTHON3_WITH_PYTHON2% -m " not integrationtest"
23+ )
24+ call %PYTHON% \python.exe setup.py bdist_wheel
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments