Closed rixed closed 6 years ago
When breaking string literals with \ then qtest does not count lines properly, and report errors as if the literals were occupying only one line. Exemple:
in testme.ml:
testme.ml
let x = "hello \ \ \ I'm line 5 but I'm innocent!" (*$T badaboum! *)
Makefile:
all: all_tests.opt ./all_tests.opt %.cmx: %.ml ocamlfind ocamlopt -o $@ -c $< all_tests.ml: testme.ml qtest --shuffle -o $@ extract $^ all_tests.opt: testme.cmx all_tests.ml ocamlfind ocamlopt -o $@ -package qcheck -linkpkg $^ clean: $(RM) all_tests.* *.cmx *.cmi *.opt *.o *.cache *.log
On qtest master, one get:
File "testme.ml", line 5, characters 11-12: Error: Syntax error: operator expected.
line 5 is wrong.
line 5
This is annoying especially whit large blocks of ($injected) code.
I will look at it, thank you!
When breaking string literals with \ then qtest does not count lines properly, and report errors as if the literals were occupying only one line. Exemple:
in
testme.ml
:Makefile:
On qtest master, one get:
line 5
is wrong.This is annoying especially whit large blocks of ($injected) code.