Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The
run_tests()
utility has been updated so that it is now designed specifically to run the complete build tests. It can still be used for development testing but it will be relatively slow compared topython setup.py build_ext --inplace
.run_tests()
now usespytest
to run the build tests. Fortunately the unit tests scripts do not need to be changed for this (although they should eventually be converted from the unittest approach).requirements-test.txt
file has been created for the necessary build test packages. This is currently justpytest
.run_tests()
now uses whatever pyodbc package is currently available (typically installed into a venv bytox
).run_tests()
doesn't look for any .pyd file anymore. For build testing, I'm hoping we can move away from the .pyd approach.tox
has been enhanced so it can now retrieve database connection string info from a local configuration file set up by the user (defaulttmp/database.cfg
although it can be overridden by PYODBC_DATABASE_CFG). Note, this is different from the existing default config filetmp/setup.cfg
as mentioned in the unit test scripts. However, I do think it's better to use "setup.cfg" only for project configuration, not for any local development stuff.Lastly, I'm very keen to move the unit test scripts into database-specific folders, in order to make test discovery easy. However, this will be tricky for Python 2.7 (which pytest doesn't support). I am creating a draft PR for that, which will act as a placeholder until we have dropped Python 2.7.