Commit Graph

27 Commits

Author SHA1 Message Date
Jay Kamat
3e816f5f8b
Update copyright for 2019 2019-02-22 21:45:08 -08:00
Florian Bruhin
9eeaa4f45d Fix lineparser tests 2018-08-07 17:53:26 +02:00
Florian Bruhin
6f028e9ad0 Update copyright years 2018-02-05 12:19:50 +01:00
Ryan Roden-Corrent
1e1335aa5e Make various SQL code review changes.
- Fix outdated comments
- Use mock specs when possible
- More precise error message check in test_import_txt_invalid.
- Fix copyright message
- Tweak missing pyqt error message
- Dead code: remove group_by and where from sqlcategory.
  With the new separate completion table, these are no longer used.
- Move test_history out of webkit/. History is no longer purely webkit
  related, it could be webengine.
2017-07-03 09:45:08 -04:00
Ryan Roden-Corrent
262b028ee9 Match error message in lineparser test. 2017-06-29 20:49:05 -04:00
Ryan Roden-Corrent
39b561a182 Fix BaseLineParser::test_double_open.
Don't tie the test to a particular error message. Ths failed because a
typo was fixed (AppendLineParser -> LineParser).
2017-06-19 07:44:11 -04:00
Ryan Roden-Corrent
784d9bb043 Remove code rendered dead by sql implementation.
Vulture exposed the following dead code:

- AppendLineParse was only used for reading the history text file, which is now
  a sql database (and the import code for the old text file is simpler and does
  not need a complex line parser)

- async_read_done is no longer used as importing the history text file is
  synchronous (and should only happen once)

- config._init_key_config is unused as it was moved to keyconf.init
2017-06-19 07:44:11 -04:00
Florian Bruhin
ea2fbc427a tests: Use match= for pytest.raises 2017-05-23 09:36:00 +02:00
Florian Bruhin
00a7a0cee6 Reorganize pylint config
This removes various stuff we don't need anymoe, and also re-enables and fixes
the import order check.
2017-05-17 20:20:12 +02:00
Florian Bruhin
822623f2ed Finally update copyrights... 2017-05-09 21:37:03 +02:00
Florian Bruhin
81d67f8a2c Remove support for an empty data/config/cachedir
See #2115
2016-11-14 23:13:21 +01:00
Daniel Karbach
6e510372fb more cleanup
jeez, this is getting embarrassing
2016-10-27 15:50:17 +02:00
Daniel Karbach
23a62e952d another lineparser/utilcmds test revision
* verify exception message in lineparser double open
* check for hunter with `pytest.importorskip`
* stricter exception checking in debug_trace test
2016-10-27 14:56:28 +02:00
Daniel Karbach
64cf8fcd39 lineparser/utilcmds test cleanup
* fix date in copyright
* remove redundant class docstrings
* don't rename utilcmds module in unit test
* use `mode_manager` fixture in place of FakeModeMan
* some whitespace
2016-10-27 14:23:01 +02:00
Daniel Karbach
9038b28ea4 different mocking of open() in lineparser test
apparently, python 3.4 (and less, probably) does not import
builtins into modules
2016-10-25 08:52:08 +02:00
Daniel Karbach
bdb96becd6 unit tests for misc.lineparser 2016-10-24 17:10:47 +02:00
Florian Bruhin
aae205030c Add missing import 2016-06-09 10:29:16 +02:00
Florian Bruhin
d6926f0622 Fix expected data in AppendLineParser test
There were two different issues here:

- `\n` rather than `os.linesep` was used, which caused the "generated"
  file to have less data in it than expected
- A final `os.linesep` (or `\n`) was missing, but that was cancelled out
  by a off-by-one error when slicing, so wasn't an issue until we tried
  with \r\n endings.
2016-06-09 10:26:09 +02:00
Florian Bruhin
a870a2888f Improve LineParser clear tests 2016-06-08 11:33:37 +02:00
Florian Bruhin
44f626134b Use real files for lineparser tests 2016-06-08 11:33:37 +02:00
Florian Bruhin
1d51d63f0c LineParser tests: Clear self._data in _open 2016-06-08 10:36:46 +02:00
Florian Bruhin
b09fe8dca0 Document LineParserMixin attributes 2016-06-08 10:22:55 +02:00
Florian Bruhin
33bcced4a2 Add a test for AppendLineParser.clear 2016-06-08 10:11:59 +02:00
Florian Bruhin
a5f2ac5f03 Adjust copyright years. 2016-01-04 07:12:39 +01:00
Florian Bruhin
150a83d8f4 pylint: Remove unneeded supressions. 2015-12-01 22:03:58 +01:00
Florian Bruhin
f7a13fa1f9 Rename LineParserWrapper to LineParserMixin.
This makes pylint shut up as it realizes it is, in fact, a mixin.
2015-11-30 07:11:35 +01:00
Florian Bruhin
2c5269acd6 Reorganize tests directory. 2015-08-18 20:19:02 +02:00