Apache-Singleton
view release on metacpan or search on metacpan
#!perl
use strict;
use warnings FATAL => 'all';
use lib qw(blib/lib);
use Apache::TestRunPerl ();
# mod_auth can cause test failures if in the wrong spot in the
# Apache chain, so we just make sure it does not get added. (test case: static
# mod_perl build and everything else as a DSO).
Apache::TestConfig::autoconfig_skip_module_add('mod_auth.c');
Apache::TestRunPerl->new->run(@ARGV);
t/multiclass.t view on Meta::CPAN
use strict;
use lib qw(t/mock lib);
use Test::More tests => 3;
use Mock::Apache;
package Printer;
use base qw(Apache::Singleton);
package Printer::Device;
use base qw(Apache::Singleton);
t/new_instance.t view on Meta::CPAN
#!/usr/bin/env perl
#
use strict;
use lib qw(t/mock lib);
use Test::More;
use Mock::Apache;
package Printer;
use base qw(Apache::Singleton);
package main;
my $printer_a = Printer->instance(foo => 'bar');
my $printer_b = Printer->instance;
t/process.t view on Meta::CPAN
use strict;
use lib qw(t/mock t/lib lib);
use Test::More tests => 4;
use Mock::Apache;
use mod_perl;
use Printer::PerProcess;
use Printer::Device::PerProcess;
my $printer_a = Printer::PerProcess->instance;
my $printer_b = Printer::PerProcess->instance;
my $printer_d1 = Printer::Device::PerProcess->instance;
t/request.t view on Meta::CPAN
use strict;
use lib qw(t/mock t/lib lib);
use Test::More tests => 4;
use Mock::Apache;
use mod_perl; # simulate MP1
use Printer::PerRequest;
use Printer::Device::PerRequest;
my $printer_a = Printer::PerRequest->instance;
my $printer_b = Printer::PerRequest->instance;
my $printer_d1 = Printer::Device::PerRequest->instance;
t/request_mp2.t view on Meta::CPAN
#!perl
#
# tests for mod_perl2
#
use strict;
use lib qw(t/mock t/lib lib);
use Test::More tests => 4;
use Mock::Apache;
use mod_perl2; # simulate MP2
use Printer::PerRequest;
use Printer::Device::PerRequest;
my $printer_a = Printer::PerRequest->instance;
my $printer_b = Printer::PerRequest->instance;
my $printer_d1 = Printer::Device::PerRequest->instance;
t/singleton.t view on Meta::CPAN
use strict;
use lib qw(t/mock lib);
use Test::More tests => 2;
use Mock::Apache;
package Printer;
use base qw(Apache::Singleton);
package main;
{
my $printer_a = Printer->instance;
my $printer_b = Printer->instance;
( run in 0.606 second using v1.01-cache-2.11-cpan-87723dcf8b7 )