File tree Expand file tree Collapse file tree 5 files changed +9
-13
lines changed
Expand file tree Collapse file tree 5 files changed +9
-13
lines changed Original file line number Diff line number Diff line change @@ -30,17 +30,13 @@ addons:
3030 - ca-certificates-mono
3131
3232before_install :
33- # Set-up location where `Python.Test.dll` will be output
34- - export PYTHONPATH=`pwd`:$PYTHONPATH
35-
3633 # Set-up dll path for embedded tests
3734 - PY_LIBDIR=$(python -c 'import sysconfig; print(sysconfig.get_config_var("LIBDIR"))')
3835 - export LD_LIBRARY_PATH=$PY_LIBDIR:$LD_LIBRARY_PATH
3936
4037install :
4138 - pip install --upgrade -r requirements.txt
42- # `setup.py install` works too, but need to deal with `Python.Test` PATH
43- - coverage run setup.py build_ext --inplace
39+ - coverage run setup.py install
4440
4541script :
4642 - python -m pytest
Original file line number Diff line number Diff line change @@ -19,9 +19,6 @@ environment:
1919 - PYTHON_VERSION : 3.6
2020
2121init :
22- # Prepare Environment
23- - mkdir C:\testdir
24-
2522 # Update Environment Variables based on matrix/platform
2623 - set PY_VER=%PYTHON_VERSION:.=%
2724 - set PYTHON=C:\PYTHON%PY_VER%
@@ -44,8 +41,6 @@ build_script:
4441
4542test_script :
4643 - pip install --no-index --find-links=.\dist\ pythonnet
47- - ps : Copy-Item .\src\testing\bin\Python.Test.dll C:\testdir\
48-
4944 - ps : .\ci\appveyor_run_tests.ps1
5045 - ps : .\ci\appveyor_build_recipe.ps1
5146
Original file line number Diff line number Diff line change 103103 <TargetAssemblyPdb >$(TargetDir)$(TargetName).pdb</TargetAssemblyPdb >
104104 </PropertyGroup >
105105 <Target Name =" AfterBuild" >
106- <Copy SourceFiles =" $(TargetAssembly)" DestinationFolder =" $(PythonBuildDir) " />
106+ <Copy SourceFiles =" $(TargetAssembly)" DestinationFolder =" $(SolutionDir)\src\tests\fixtures " />
107107 <Copy SourceFiles =" $(TargetAssemblyPdb)" Condition =" Exists('$(TargetAssemblyPdb)')" DestinationFolder =" $(PythonBuildDir)" />
108108 </Target >
109109</Project >
Original file line number Diff line number Diff line change 55"""Helpers for testing."""
66
77import ctypes
8+ import os
89import sys
910import sysconfig
1011
1112import clr
1213
13- # Add path for Python.Test & Add References
14- sys .path .append ('C:/testdir/' )
14+ # Add path for `Python.Test`
15+ cwd = os .path .dirname (__file__ )
16+ fixtures = os .path .join (cwd , 'fixtures' )
17+ sys .path .append (fixtures )
18+
19+ # Add References for tests
1520clr .AddReference ("Python.Test" )
1621clr .AddReference ("System.Collections" )
1722clr .AddReference ("System.Data" )
You can’t perform that action at this time.
0 commit comments