summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
...
* Test code cleanup; remove VERBOSE global and activate all related print() ↵Paul McGuire2020-02-231-75/+86
| | | | statements; remove dead ParseTest class; cleanup testSkipToParserTests test using assertRaisesParseException; fix parsers in pickle compatibility tests, and remove PickleTest_Greeting class as ParseResults wrapper; change test classes created using type() with more explicit class definitions
* Add Black formatting Git hook (#180)Kyle Lahnakoski2020-02-232-0/+11
| | | | | | | | | | | | | | | | | | * add black git hook * test change * test instructions, fix instructions * spelling * make tox and pre-commit agree on line length * start guessing what the line length parameter really is * 80 char line length * 88?
* Add unit tests to expand test coverage (#184)Matt Carmody2020-02-231-1/+114
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add unit test for pop with invalid named arg * Add unit test for setParseAction() with uncallable arg * Add unit test for __mul__ with negative number * Add unit test for __mul__ with Ellipsis * Add unit tests for matchOnlyAtCol * Add unit tests for convertToDate and converToDatetime * blacken the new tests * Add unit test for assertParseAndCheckDict * Update with feedback from ptmcg Removed unnecessary imports Replaced exception prints with ptmcg's assertRaises override * blacken updates * Update tests with additional feedback Change assertRaises(ParseException) to assertRaisesParseException() Return exception in overrided assertRaises
* Add unit test sequences for small and unbounded packrat cachesptmcg2020-02-041-0/+33
|
* Update unit tests to use pyparsing_test assert methodsPaul McGuire2020-01-271-111/+77
|
* Some unittest.TestCase cleanups (#175); black reformat of core.pyptmcg2020-01-261-266/+245
|
* Added new warning 'warn_on_match_first_with_lshift_operator' to warn when ↵ptmcg2020-01-261-4/+34
| | | | doing `fwd << a | b`; fixed potential FutureWarning when including unescaped '[' in a regex range definition.
* Break up testMiscellaneousParserTests unit test into separate test methodsptmcg2020-01-041-252/+237
|
* Rollforward infixNotation ternary op fix from 2.4.6 branch, plus related ↵ptmcg2020-01-042-3/+17
| | | | unit test; change TestParseResultsAsserts to mixin instead of subclass; rollforward 2.4.6 CHANGES blurb from 2.4.6 branch
* Include 2.4.x change notes to CHANGES; add select_parser to unit tests; ↵ptmcg2019-11-181-0/+3
| | | | minor changes to select_parser
* Use assertRaises for tests that raise exceptions (#160)Jon Dufresne2019-11-021-41/+10
|
* Use classmethod decorator (#159)Jon Dufresne2019-11-021-12/+4
| | | | | Available since Python 2.4. https://docs.python.org/3/library/functions.html#classmethod
* Use staticmethod decorator (#158)Jon Dufresne2019-11-021-21/+8
| | | | | Available since Python 2.4. https://docs.python.org/3/library/functions.html#staticmethod
* Blacken the project (#141)Jon Dufresne2019-10-313-1741/+3593
|
* Some code header cleanup; remove BUFFER_OUTPUT from test_unit.py, and ↵Paul McGuire2019-10-243-34/+19
| | | | replace most resetting() context managers and try-finallys with ppt.reset_pyparsing_context
* Use pyupgrade to upgrade the code to use Python3 conventions (#138)Jon Dufresne2019-10-242-67/+65
| | | | | | | | | | | | The pyupgrade project is available at https://github.com/asottile/pyupgrade and can be installed through pip. The pyupgrade tool automatically upgrades syntax for newer versions of the language. As pyparsing is now Python 3 only, can apply some cleanups and simplifications. Ran the tool using the following command: $ find . -name \*.py -exec pyupgrade --py3-plus {} \; For now, pyparsing.py was skipped while it is refactored to a package.
* refactor tests into tests directory (#130)Kyle Lahnakoski2019-10-218-0/+5899