lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Use of ly:expect-warning in regtests


From: Michael Käppler
Subject: Use of ly:expect-warning in regtests
Date: Fri, 2 Oct 2020 14:24:20 +0200
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0

Hi all,
while fixing the issue Dan brought up (ottavation markups and MIDI
output) and looking
through the existing regtest ottavation-markups.ly, I noticed that it
does output a warning (as intended).
Other regtests, however, use ly:expect-warning to suppress these
warnings and output a new warning instead, if
the expected warning is missing.

Some "statistics":
Regtests, that _do_ output a warning

grep 'warning: ' lilypond/build/input/regression/out-test-baseline/*.log
| wc -l
52
(There are some warnings for missing expected warnings included, however)

Regtests, that use ly:expect-warning

git grep '(ly:expect-warning' input/regression/* | wc -l
118

Some use ly:expect-warning in combination with ly:set-option
'warning-as-error.
Mostly they set it to #f:

git grep "(ly:set-option 'warning-as-error #f" input/regression/* | wc -l
39

But some set it to #t:
git grep "(ly:set-option 'warning-as-error #t" input/regression/* | wc -l
9

Normally, 'warning-as-error is set to #f, anyway. Why is it necessary to
manually set it to #f?

It would be great if somebody could enlighten me here and tell me the
underlying policy,
what is considered good practise for the regtests. (if there is any)

Thanks in advance,
Michael






reply via email to

[Prev in Thread] Current Thread [Next in Thread]