Update to hide modules from the PAUSE Indexer.
[dbsrgits/DBIx-Class.git] / t / 19quotes.t
CommitLineData
2a816814 1use strict;
2use Test::More;
3use IO::File;
4
5BEGIN {
6 eval "use DBD::SQLite";
7 plan $@
8 ? ( skip_all => 'needs DBD::SQLite for testing' )
2437a1e3 9 : ( tests => 4 );
2a816814 10}
11
12use lib qw(t/lib);
13
14use_ok('DBICTest');
15
22b15c96 16use_ok('DBICTest::HelperRels');
17
2437a1e3 18DBICTest->schema->storage->sql_maker->quote_char("'");
19DBICTest->schema->storage->sql_maker->name_sep('.');
2a816814 20
21my $rs = DBICTest::CD->search(
54540863 22 { 'me.year' => 2001, 'artist.name' => 'Caterwauler McCrae' },
2a816814 23 { join => 'artist' });
24
25cmp_ok( $rs->count, '==', 1, "join with fields quoted");
26
2437a1e3 27DBICTest->schema->storage->sql_maker->quote_char([qw/[ ]/]);
28DBICTest->schema->storage->sql_maker->name_sep('.');
29
30$rs = DBICTest::CD->search(
31 { 'me.year' => 2001, 'artist.name' => 'Caterwauler McCrae' },
32 { join => 'artist' });
33cmp_ok($rs->count,'==', 1,"join quoted with brackets.");
34
35
36
37