Bug #30762 "Got one of the listed errors" not filtered by --disable_warnings
Submitted: 2 Sep 2007 22:06 Modified: 5 Sep 2008 15:22
Reporter: Hartmut Holzgraefe Email Updates:
Status: Won't fix Impact on me:
None 
Category:MySQL Server: Tests Severity:S3 (Non-critical)
Version:5.0, 5.1 OS:Any
Assigned to: Magnus Blåudd CPU Architecture:Any

[2 Sep 2007 22:06] Hartmut Holzgraefe
Description:
mysqltest will still throw a "Got one of the listed errors" message
on a statement where acceptable errors are defined with --error
when the statement and --error directive are enclosed within a 
--disable_warnings / --enable_warnings block

IMHO there should be a way to surpress the "Got one of the listed errors"
message, either by --disable_warnings or by an option of its own

How to repeat:
will attach test case ...

Suggested fix:
filter "Got one of the listed errors" if --disable_warnings is active (preferred) or add another option for this
[2 Sep 2007 22:13] Hartmut Holzgraefe
Test:

   --disable_warnings
   --error 1583, 1126
   CREATE AGGREGATE FUNCTION avg RETURNS REAL SONAME "no_such.so";
   --enable_warnings

Expected result:
 
   CREATE AGGREGATE FUNCTION avg RETURNS REAL SONAME "no_such.so";

Actual result:

   CREATE AGGREGATE FUNCTION avg RETURNS REAL SONAME "no_such.so";
   Got one of the listed errors
[2 Sep 2007 22:15] Hartmut Holzgraefe
mysqltest test case

Attachment: bug30762.tgz (application/x-gtar, text), 744 bytes.

[16 Feb 2008 11:58] Magnus Blåudd
Will look more carefully, but it feels like that is exactly how it should work.
--disable_warnings will just disable the SHOW WARNINGS command that we run after each query to the server.
[5 Sep 2008 15:22] Magnus Blåudd
The manual says:
"# disable_warnings, enable_warnings

Disable or enable warnings. This setting is enabled by default. With this setting enabled, mysqltest uses SHOW WARNINGS to display any warnings produced by SQL statements.

--disable_warnings
--enable_warnings
"

i.e only warnings produced by a query to the MySQL Server should be suppressed by disable_warnings