CPAN Security Tip #2/3: Make sure none of your favourite CPAN dists are unmaintained! Learn more

use strict;
use Test::More 'tests' => 4;
# Test.
my $obj = Tags::HTML::Container->new;
my $ret = $obj->init;
is($ret, undef, 'Run of init (without callback).');
# Test.
$obj = Tags::HTML::Container->new;
my $i = 0;
my $cb = sub { $i++ };
$ret = $obj->init($cb);
is($ret, undef, 'Run of init (with callback).');
is($i, 1, 'Get i value after call of callback (1).');