annotate _test/Test/Web/Application.pm @ 61:8d0ae27d15c1

minor changes
author wizard
date Wed, 10 Mar 2010 16:41:46 +0300
parents b0c068da93ac
children 76b878ad6596
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
60
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
1 package Test::Web::Application::Instance;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
2 package Test::Web::Application;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
3 use strict;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
4 use base qw(IMPL::Test::Unit);
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
5
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
6 use IMPL::Test qw(test failed);
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
7 require IMPL::Web::Application;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
8
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
9 __PACKAGE__->PassThroughArgs;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
10
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
11 sub CTOR {
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
12 # simulate CGI environment
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
13 }
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
14
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
15 test SpawnApp => sub {
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
16 my $instance = spawn Test::Web::Application::Instance('Resources/app.xml');
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
17
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
18 return 1;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
19 };
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
20
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
21 test ActivateOnDemand => sub {
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
22 my $instance = spawn Test::Web::Application::Instance('Resources/app.xml');
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
23
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
24 my $ds = $instance->dataSource;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
25
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
26 return 1;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
27 };
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
28
61
8d0ae27d15c1 minor changes
wizard
parents: 60
diff changeset
29 test SaveXml => sub {
8d0ae27d15c1 minor changes
wizard
parents: 60
diff changeset
30 my $instance = spawn Test::Web::Application::Instance('Resources/app.xml');
8d0ae27d15c1 minor changes
wizard
parents: 60
diff changeset
31
8d0ae27d15c1 minor changes
wizard
parents: 60
diff changeset
32 warn $instance->xml;
8d0ae27d15c1 minor changes
wizard
parents: 60
diff changeset
33 };
8d0ae27d15c1 minor changes
wizard
parents: 60
diff changeset
34
60
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
35 package Test::Web::Application::Instance;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
36 use base qw(IMPL::Web::Application);
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
37
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
38 __PACKAGE__->PassThroughArgs;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
39
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
40 use IMPL::Class::Property;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
41
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
42 BEGIN {
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
43 public property name => prop_all;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
44 public property options => prop_all;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
45 public property dataSource => prop_all;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
46 public property securityMod => prop_all;
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
47 }
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
48
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
49
b0c068da93ac Lazy activation for the configuration objects (final concept)
wizard
parents:
diff changeset
50 1;