opened
knz
username_0
My previous PR #2 introduced a bug (wasn't picked up in review).
Also wanted to enhance `ParseLine` as per Radu's suggestion in https://github.com/cockroachdb/datadriven/pull/2#issuecomment-554094575

- `ParseLine` now reports duplicate arguments on a single directive
  line. Also added tests to check this.
- there was a missing `err` return, this patch fixes it and adds a
  unit test.
- the location prefix would be reported two times, once because
  it was embedded in the error object and once because `t.Fatal`
  would prepend it again. This patch fixes it.
- the error message upon syntax errors was truncating the input
  line. This patch fixes that and also adds column information.
  Also checks this behavior via a unit test.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/cockroachdb/datadriven/4)
<!-- Reviewable:end -->
Fix syntax error checks
issue
created
knz
username_0
tfyr
comment