Acme-Free-Advice-Unsolicited

 view release on metacpan or  search on metacpan

t/00_compile.t  view on Meta::CPAN

    isa_ok $slip, ['Acme::Free::Advice::Unsolicited'], 'advice is a blessed hash';
};
subtest 'specific advice' => sub {
    is my $slip = advice(224), hash {
        field advice => string q[You can be whatever you want, so be the person who ends meetings early.];
        field id     => number 224;
        field source => string q[https://kk.org/thetechnium/103-bits-of-advice-i-wish-i-had-known/];
        end;
    }, 'advice(224) returns a known piece of wisdom';
    isa_ok $slip, ['Acme::Free::Advice::Unsolicited'], 'slip is a blessed hash';
    is advice(100000), U(), 'advice(100000) returns undef';
};
subtest 'gather all advice' => sub {
    is my $list = [ all() ], array {
        all_items hash {
            field advice => D();
            field id     => D();
            field source => D();
            end;
        };
        etc;



( run in 2.314 seconds using v1.01-cache-2.11-cpan-d80b1682f3f )