0dd87b94cfb8b012845237a8b48dedf5448a837a
[dbsrgits/DBIx-Class.git] / t / cdbi / early_column_heisenbug.t
1 use strict;
2
3 use Test::More;
4
5 use lib 't/cdbi/testlib';
6 use DBIC::Test::SQLite (); # this will issue the necessary SKIPs on missing reqs
7
8 {
9     package Thing;
10     use base qw(DBIx::Class::CDBICompat);
11 }
12
13 {
14     package Stuff;
15     use base qw(DBIx::Class::CDBICompat);
16 }
17
18 # There was a bug where looking at a column group before any were
19 # set would cause them to be shared across classes.
20 is_deeply [Stuff->columns("Essential")], [];
21 Thing->columns(Essential => qw(foo bar baz));
22 is_deeply [Stuff->columns("Essential")], [];
23
24 done_testing;