summaryrefslogtreecommitdiffstats
path: root/clang/bindings/python/tests/cindex/test_tokens.py
Commit message (Collapse)AuthorAgeFilesLines
* [python] [tests] Support overriding library path via environmentMichal Gorny2018-10-111-0/+5
| | | | | | | | | | | | | | | | | Support a new CLANG_LIBRARY_PATH environment variable for the Python binding tests. This variable can be used to force the bindings to load libclang.* from a specific directory. I plan to use this when integrating Python binding tests with the CMake build system. Currently, those tests load libclang.so from default search paths, so I would have to rely on platform-specific mechanics such as LD_LIBRARY_PATH. Instead of copying the whole logic necessary to handle platform differences into yet another place, it's easier to just add a dedicated variable for this purpose. Differential Revision: https://reviews.llvm.org/D52806 llvm-svn: 344240
* [python] [tests] Rewrite to use standard unittest moduleMichal Gorny2017-11-101-34/+36
| | | | | | | | | | | | | | | | | | | | | | | | | Rewrite the tests from using plain 'assert' mixed with some nosetests methods to the standard unittest module layout. Improve the code to use the most canonical assertion methods whenever possible. This has a few major advantages: - the code uses standard methods now, resulting in a reduced number of WTFs whenever someone with basic Python knowledge gets to read it, - completely unnecessary dependency on nosetests is removed since the standard library supplies all that is necessary for the tests to run, - the tests can be run via any test runner, including the one built-in in Python, - the failure output for most of the tests is improved from 'assertion x == y failed' to actually telling the values. Differential Revision: https://reviews.llvm.org/D39763 llvm-svn: 317897
* [libclang] Fix python testsSergey Kalinichev2016-12-031-1/+1
| | | | | | It was broken in r286421 llvm-svn: 288582
* [clang.py] Implement Token APIGregory Szorc2012-07-121-0/+52
llvm-svn: 160111
OpenPOWER on IntegriCloud