[Dbix-class] test failures in DBIx::Class v0.06999_03

Carl Franks fireartist at gmail.com
Wed Jun 28 17:14:16 CEST 2006


On 28/06/06, Matt S Trout <dbix-class at trout.me.uk> wrote:
> Carl Franks wrote:
> > On 27/06/06, Matt S Trout <dbix-class at trout.me.uk> wrote:
> >> Brandon Black wrote:
> >>> On 6/27/06, Matt S Trout <dbix-class at trout.me.uk> wrote:
> >>>> Carl Franks wrote:
> >>>>> t\71mysql.......................NOK 5
> >>>>> #   Failed test 'columns_info_for - column data types'
> >>>>> #   in t\71mysql.t at line 71.
> >>>>> #     Structures begin differing at:
> >>>>> #          $got->{charfield}{data_type} = 'VARCHAR'
> >>>>> #     $expected->{charfield}{data_type} = 'CHAR'
> >>>>> # Looks like you failed 1 test of 5.
> >>>> Argh. I'm sure we changed this because of test failures for somebody else. Can
> >>>> anybody else with MySQL run this please and see if it's a uniform failure?
> >>>>
> >>> Its not.  I just tested the CPAN tarball of 0.06999_03 here and got
> >>> success on 71mysql.t.  Relevant environmental details:
> >> Right. Sod it. Test disabled until we figure out how to deal with this
> >> properly. I'm not blocking a release because either mysql or its DB is retarded.
> >
> > woohoo! - "Silent Column Specification Changes" :)
> > http://dev.mysql.com/doc/refman/5.0/en/silent-column-changes.html
> >
> > If any column in a table has a variable length, the entire row becomes
> > variable-length as a result. Therefore, if a table contains any
> > variable-length columns (VARCHAR, TEXT, or BLOB), all CHAR  columns
> > longer than three characters are changed to VARCHAR columns.
> >
> > These occur prior to MySQL 5.0.3. As of 5.0.3, an error occurs if a
> > column cannot be created using the specified data type.
>
> Can you try fiddling the data types in that test so it remains sane after
> mysql's been retarded at it? If we can get 4.x to not coerce, presumably 5.x
> will pass the same tests again.

Change the create table SQL, so that _both_ cols are either VARCHAR _or_ CHAR.
And change both the data_type in $test_type_info

I've just tried both methods - (1) both CHAR - (2) both VARCHAR
Either way resulted in all tests passing.

I've attached a patch.

Carl
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 71mysql.t.diff
Type: application/octet-stream
Size: 777 bytes
Desc: not available
Url : http://lists.rawmode.org/pipermail/dbix-class/attachments/20060628/660c23a6/attachment.obj 


More information about the Dbix-class mailing list