The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.
use strict;
use warnings;
use lib './t/lib';
use Test::More;
use Mock::Container;

subtest 'export container function' => sub {

    eval { container('foo') };
    isa_ok container('foo'), 'Mock::Foo';
    is container('foo')->say, 'foo';

    eval { container('bar') };
    ok $@;
};

done_testing;