Bug #53303 mytap tests should always have a plan()
Submitted: 30 Apr 2010 7:35 Modified: 14 Oct 2010 14:52
Reporter: Tor Didriksen Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Tests Severity:S3 (Non-critical)
Version: OS:Any
Assigned to: Tor Didriksen CPU Architecture:Any

[30 Apr 2010 7:35] Tor Didriksen
Description:
SunOS tyr40 5.10 Generic_127128-11 i86pc i386 i86pc
Thu Apr 29 20:06:28 CEST 2010
+ perl unit.pl run
Running tests: examples mysys
examples/no_plan-t.....FAILED before any test output arrived
examples/simple-t......ok
examples/skip-t........ok
        2/4 skipped: Example of skipping a few test points in a test
examples/skip_all-t....skipped
        all skipped: Example of skipping an entire test
examples/todo-t........ok
mysys/base64-t.........ok
mysys/bitmap-t.........ok
mysys/lf-t.............ok
mysys/my_atomic-t......ok
mysys/my_rdtsc-t.......ok
mysys/my_vsnprintf-t...ok
Failed Test        Stat Wstat Total Fail  Failed  List of Failed
-------------------------------------------------------------------------------
examples/no_plan-t               ??   ??       %  ??
1 test and 2 subtests skipped.
Failed 1/11 test scripts, 90.91% okay. 3/3110 subtests failed, 99.90% okay.
+ echo '[SOURCEBUILDER] FAIL see log'
[SOURCEBUILDER] FAIL see log

How to repeat:
Happens on solaris.
See also 
Bug #47540  Backup unit tests errors on Solaris

Suggested fix:
Invoke plan(NO_PLAN) before running any tests.
[30 Apr 2010 7:42] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107036

3162 Tor Didriksen	2010-04-30
      Bug#53303 mytap tests should always have a plan()
     @ unittest/examples/no_plan-t.c
        Always invoke plan()
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[3 May 2010 7:57] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107160

3164 Tor Didriksen	2010-05-03
      Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
     @ unittest/examples/no_plan-t.c
        Always invoke plan()
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[3 May 2010 10:56] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107173

3165 Tor Didriksen	2010-05-03
      Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
     @ unittest/examples/no_plan-t.c
        Always invoke plan()
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[3 May 2010 11:46] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107182

3166 Tor Didriksen	2010-05-03
      Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
     @ unittest/examples/no_plan-t.c
        Always invoke plan()
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[4 May 2010 5:57] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107238

3161 Tor Didriksen	2010-05-03
      Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
     @ unittest/examples/no_plan-t.c
        Always invoke plan()
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[4 May 2010 6:27] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107239

3161 Tor Didriksen	2010-05-04
      Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
      
      Also fix some compile warnings (formal parameter different from declaration)
     @ unittest/examples/no_plan-t.c
        Always invoke plan()
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[4 May 2010 13:34] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107334

3165 Tor Didriksen	2010-05-04
      Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
      
      Also fix some compile warnings (formal parameter different from declaration)
     @ unittest/examples/no_plan-t.c
        Comment that we recommend calling plan(NO_PLAN)
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[4 May 2010 13:37] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/107335

3863 Tor Didriksen	2010-05-04 [merge]
      Merge from next-mr-bugfixing:
      Bug#53303 mytap tests should always have a plan()
[4 May 2010 13:38] Tor Didriksen
pushed to
bzr+ssh://bk-internal.mysql.com/bzrroot/server/mysql-next-mr-bugfixing/
bzr+ssh://bk-internal.mysql.com/bzrroot/server/mysql-6.0-codebase-bugfixing/
[7 May 2010 9:20] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20100507091908-vqyhpwf2km0aokno) (version source revid:alik@sun.com-20100507091737-12vceffs11elb25g) (merge vers: 6.0.14-alpha) (pib:16)
[7 May 2010 9:23] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100507091823-nzao4h3qosau4tin) (version source revid:alik@sun.com-20100507091720-ib9r8uny2aeazvas) (pib:16)
[8 May 2010 17:06] Paul DuBois
Changes to test suite. No changelog entry needed.
[4 Jun 2010 12:21] Tor Didriksen
Due to buffering of output, tests which do not call plan() will fail on some platforms. (the title of the bug is misleading, the fix was to flush, rather than enforce plan())

Asking for re-triage, to backport to 5.1 and trunk.
[10 Jun 2010 11:16] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/110707

3424 Tor Didriksen	2010-06-10
      Backport of Bug#53303 mytap tests should always have a plan()
      
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
        
      Also fix some compile warnings (formal parameter different from declaration)
     @ unittest/examples/Makefile.am
        Omit core-t, since it will always fail.
     @ unittest/examples/no_plan-t.c
        Comment that we recommend calling plan(NO_PLAN)
     @ unittest/mytap/tap.c
        Use the named constant NO_PLAN
        Flush all output.
     @ unittest/mytap/tap.h
        Change documentation for the plan() function.
[10 Jun 2010 11:23] Tor Didriksen
Backported, pushed to mysql-5.1-bugteam
Merged, pushed to mysql-trunk-merge
[10 Jun 2010 12:06] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/110715

3055 Tor Didriksen	2010-06-10 [merge]
      Merge fix for Bug#53303 from 5.1-bugteam
      
      text conflict: unittest/examples/Makefile.am
[17 Jun 2010 6:13] Bugs System
Pushed into 5.5.5-m3 (revid:alexey.kopytov@sun.com-20100615145247-8bj0vmuqlotbqsn9) (version source revid:tor.didriksen@sun.com-20100610112135-95h3vkbbdh5f9cdw) (merge vers: 5.5.5-m3) (pib:16)
[17 Jun 2010 6:17] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100615150216-cubqoyn1fj9b6a2p) (version source revid:alik@ibmvm-20100610135644-1iuskuj58nale9n3) (pib:16)
[19 Jul 2010 14:36] Bugs System
Pushed into 5.1.49 (revid:build@mysql.com-20100719143034-omcma40sblwmay3x) (version source revid:tor.didriksen@sun.com-20100610111535-2cf4t3bgylrquzke) (merge vers: 5.1.48) (pib:16)
[20 Jul 2010 2:13] Paul DuBois
Changes to test suite. No changelog entry needed.
[4 Aug 2010 8:03] Bugs System
Pushed into mysql-trunk 5.6.1-m4 (revid:alik@ibmvm-20100804080001-bny5271e65xo34ig) (version source revid:alik@sun.com-20100507093958-2y0wy6svnc3zfgqb) (merge vers: 5.6.99-m4) (pib:18)
[4 Aug 2010 8:19] Bugs System
Pushed into mysql-trunk 5.6.1-m4 (revid:alik@ibmvm-20100804081533-c1d3rbipo9e8rt1s) (version source revid:alik@sun.com-20100507093958-2y0wy6svnc3zfgqb) (merge vers: 5.6.99-m4) (pib:18)
[4 Aug 2010 19:57] Paul DuBois
Changes to test suite. No changelog entry needed.
[14 Oct 2010 8:27] Bugs System
Pushed into mysql-5.1-telco-7.0 5.1.51-ndb-7.0.20 (revid:martin.skold@mysql.com-20101014082627-jrmy9xbfbtrebw3c) (version source revid:vasil.dimov@oracle.com-20100531152341-x2d4hma644icamh1) (merge vers: 5.5.5-m3) (pib:21)
[14 Oct 2010 8:42] Bugs System
Pushed into mysql-5.1-telco-6.3 5.1.51-ndb-6.3.39 (revid:martin.skold@mysql.com-20101014083757-5qo48b86d69zjvzj) (version source revid:vasil.dimov@oracle.com-20100531152341-x2d4hma644icamh1) (merge vers: 5.5.5-m3) (pib:21)
[14 Oct 2010 8:57] Bugs System
Pushed into mysql-5.1-telco-6.2 5.1.51-ndb-6.2.19 (revid:martin.skold@mysql.com-20101014084420-y54ecj85j5we27oa) (version source revid:vasil.dimov@oracle.com-20100531152341-x2d4hma644icamh1) (merge vers: 5.5.5-m3) (pib:21)
[14 Oct 2010 14:52] Jon Stephens
Set back to Closed per previous comment.