Download:
child 73:a9c9da814fe3
parent 71:6e9d9e772cf5
72:c6489ccdbd5b
Anton Shestakov <av6@dwimlabs.net>, Mon, 27 Jun 2016 22:58:22 +0800
incoming: remove linkstart and linkend until things are actually ready

2 файлов изменено, 1 вставок(+), 11 удалений(-) [+]
incoming.py file | annotate | diff | comparison | revisions
tests/test_incoming.py file | annotate | diff | comparison | revisions
--- a/incoming.py Sun Jun 26 20:27:35 2016 +0800
+++ b/incoming.py Mon Jun 27 22:58:22 2016 +0800
@@ -44,8 +44,6 @@
if m is not None:
item['filename'] = m.group('filename')
item['fileline'] = int(m.group('fileline'))
- item['linkstart'] = m.start('filename')
- item['linkend'] = m.end('fileline')
rest = line[m.end():]
patterns = (
--- a/tests/test_incoming.py Sun Jun 26 20:27:35 2016 +0800
+++ b/tests/test_incoming.py Mon Jun 27 22:58:22 2016 +0800
@@ -3,7 +3,7 @@
def test_match_linter_output():
mlo = match_linter_output
- usual_keys = ['cls', 'fileline', 'filename', 'linkend', 'linkstart']
+ usual_keys = ['cls', 'fileline', 'filename']
errors, warnings, extra = mlo('hello.py:42:1: W123 clowntown ahoy')
assert errors == 0
@@ -12,8 +12,6 @@
assert extra['cls'] == 'warning'
assert extra['filename'] == 'hello.py'
assert extra['fileline'] == 42
- assert extra['linkstart'] == 0
- assert extra['linkend'] == 11
errors, warnings, extra = mlo('file with spaces:007:001: [error] oops!')
assert errors == 1
@@ -22,8 +20,6 @@
assert extra['cls'] == 'error'
assert extra['filename'] == 'file with spaces'
assert extra['fileline'] == 7
- assert extra['linkstart'] == 0
- assert extra['linkend'] == 20
errors, warnings, extra = mlo('requirements.txt:1:1: PIL is obsolete.')
assert errors == 0
@@ -32,8 +28,6 @@
assert extra['cls'] == 'warning'
assert extra['filename'] == 'requirements.txt'
assert extra['fileline'] == 1
- assert extra['linkstart'] == 0
- assert extra['linkend'] == 18
errors, warnings, extra = mlo('ham.lua:414:90: (E101) foo is not good')
assert errors == 1
@@ -42,8 +36,6 @@
assert extra['cls'] == 'error'
assert extra['filename'] == 'ham.lua'
assert extra['fileline'] == 414
- assert extra['linkstart'] == 0
- assert extra['linkend'] == 11
def test_parse_project_url():