view _test/Test/Config/Container.pm @ 418:3f38dabaf5cc ref20150831

sync
author cin
date Mon, 28 Dec 2015 15:11:35 +0300
parents 3ed0c58e9da3
children b0481c071bea
line wrap: on
line source

package Test::Config::Container;
use strict;

{
    package Test::Config::Container::Baz;
    use IMPL::declare {
        base => {
            'IMPL::Object' => undef
        },
        props => [
          value => 'r'
        ]
    };
    
    sub CTOR {
        my $this = shift;
        $this->value(shift);
    }
}

use IMPL::declare {
	require => {
		Container => 'IMPL::Config::Container',
		
	},
	base => {
		'IMPL::Test::Unit' => '@_'
	}
};
use IMPL::Test qw(test assert failed);

test CreateContainer => sub {
	my $c1 = Container->new();
};

test RegisterServices => sub {
	my $c1 = Container->new();
	
	$c1->Register( 'db' => Service->new(
        type => 'Foo::Data',
        norequire => 1,
        activation => 'container'
    ));
	
	return $c1;
};

test ResolveServices => sub {
	
};


1;