aboutsummaryrefslogtreecommitdiffstats
path: root/lib/parsetools/test
diff options
context:
space:
mode:
authorHans Bolinder <[email protected]>2010-11-02 08:20:54 +0100
committerHans Bolinder <[email protected]>2010-11-02 08:20:54 +0100
commit96419fe8c795656c46ba50b1aac92c98acc73a0b (patch)
tree186d6eea822bebfa85d76b8a8a64402754416f54 /lib/parsetools/test
parenta77d2b315600bbc851d3ab6d8d70c62715d5ce7c (diff)
parent94ffa8407566de48f55036ce705924d7ee111d25 (diff)
downloadotp-96419fe8c795656c46ba50b1aac92c98acc73a0b.tar.gz
otp-96419fe8c795656c46ba50b1aac92c98acc73a0b.tar.bz2
otp-96419fe8c795656c46ba50b1aac92c98acc73a0b.zip
Merge branch 'hb/parsetools/format_yecc_messages/OTP-8919' into dev
* hb/parsetools/format_yecc_messages/OTP-8919: Improve formating of Yecc error messages
Diffstat (limited to 'lib/parsetools/test')
-rw-r--r--lib/parsetools/test/yecc_SUITE.erl12
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/parsetools/test/yecc_SUITE.erl b/lib/parsetools/test/yecc_SUITE.erl
index 93949a074a..8153be7e61 100644
--- a/lib/parsetools/test/yecc_SUITE.erl
+++ b/lib/parsetools/test/yecc_SUITE.erl
@@ -46,7 +46,7 @@
bugs/1,
otp_5369/1, otp_6362/1, otp_7945/1, otp_8483/1, otp_8486/1,
improvements/1,
- otp_7292/1, otp_7969/1]).
+ otp_7292/1, otp_7969/1, otp_8919/1]).
% Default timetrap timeout (set in init_per_testcase).
-define(default_timeout, ?t:minutes(1)).
@@ -1541,7 +1541,7 @@ otp_8486(Config) when is_list(Config) ->
ok.
improvements(suite) ->
- [otp_7292, otp_7969].
+ [otp_7292, otp_7969, otp_8919].
otp_7292(doc) ->
"OTP-7292. Header declarations for edoc.";
@@ -1773,6 +1773,14 @@ otp_7969(Config) when is_list(Config) ->
?line {error,{{1,11},erl_parse,_}} = erl_parse:parse_and_scan({F6, []}),
ok.
+otp_8919(doc) ->
+ "OTP-8919. Improve formating of Yecc error messages.";
+otp_8919(suite) -> [];
+otp_8919(Config) when is_list(Config) ->
+ {error,{1,Mod,Mess}} = erl_parse:parse([{cat,1,"hello"}]),
+ "syntax error before: \"hello\"" = lists:flatten(Mod:format_error(Mess)),
+ ok.
+
yeccpre_size() ->
yeccpre_size(default_yeccpre()).