Apache-Voodoo
view release on metacpan or search on metacpan
lib/Apache/Voodoo/Application.pm view on Meta::CPAN
}
# Same idea for JSON. What website these days doesn't use even
# a little AJAX?
unless (defined($self->{'views'}->{'JSON'})) {
require Apache::Voodoo::View::JSON;
$self->{'views'}->{'JSON'} = Apache::Voodoo::View::JSON->new();
}
# models get the config and every model except themselves
# to prevent accidental circular references
foreach my $key (keys %{$self->{'models'}}) {
my %m = map { $_ => $self->{models}->{$_} }
grep { $_ ne $key }
keys %{$self->{'models'}};
eval {
$self->{models}->{$key}->init($config->config(),\%m);
};
if ($@) {
warn "$@\n";
t/00-distribution.t view on Meta::CPAN
use Test::More;
# Not every module is supposed to be publicly used, so we need to disable the pod
# converage checks. There are also optional modules, so we have to conditionally
# decide which ones to check for compilation in a separate test.
eval {
require Test::Distribution;
};
plan(skip_all => 'Test::Distribution not installed') if $@;
import Test::Distribution only => ['description','pod'];
'a_date' => '01/01/2010',
'a_varchar' => 'another text string',
'avt_ref_table.name' => 'Second Value',
'a_datetime' => '2010-02-01 14:00:00',
'avt_ref_table_id' => 2,
'id' => 2,
'a_time' => ' 5:00 PM'
},
{
'a_varchar' => 'loren ipsum solor sit amet',
'a_text' => 'consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.',
'a_date' => '03/15/2010',
'avt_ref_table.name' => 'Fourth Value',
'a_datetime' => '2010-01-01 12:00:00',
'avt_ref_table_id' => 4,
'id' => 3,
'a_time' => ' 4:00 PM'
}
],
'NUM_MATCHES' => 3,
'LIMIT' => []
t/test_data/test_db.sql view on Meta::CPAN
a_bit bit,
a_date date,
a_time time,
a_datetime datetime,
a_varchar varchar(128),
a_text text
);
INSERT INTO avt_table VALUES(1,1,0,'2009-01-01','13:00:00','2000-02-01 12:00:00','a text string', 'a much larger text string');
INSERT INTO avt_table VALUES(2,2,1,'2010-01-01','17:00:00','2010-02-01 14:00:00','another text string', 'different much longer string');
INSERT INTO avt_table VALUES(3,4,1,'2010-03-15','16:00:00','2010-01-01 12:00:00','loren ipsum solor sit amet','consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.');
DROP TABLE IF EXISTS avt_all_types;
CREATE TABLE avt_all_types (
id int unsigned not null primary key,
bigint_not_null bigint not null,
bigint_null bigint null,
bigint_unsigned_not_null bigint unsigned not null,
bigint_unsigned_null bigint unsigned null,
char_not_null char(32) not null,
char_null char(32) null,
( run in 0.416 second using v1.01-cache-2.11-cpan-de7293f3b23 )