1#!perl -w 2use strict; 3use Module::CoreList; 4use Test::More tests => 6; 5 6BEGIN { require_ok('Module::CoreList'); } 7 8is_deeply([ Module::CoreList->find_modules(qr/warnings/) ], 9 [ qw(encoding::warnings warnings warnings::register) ], 10 'qr/warnings/'); 11 12is_deeply([ Module::CoreList->find_modules(qr/IPC::Open/) ], 13 [ qw(IPC::Open2 IPC::Open3) ], 14 'qr/IPC::Open/'); 15 16is_deeply([ Module::CoreList->find_modules(qr/Module::/, 5.008008) ], [], 'qr/Module::/ at 5.008008'); 17 18is_deeply([ Module::CoreList->find_modules(qr/Test::H.*::.*s/, 5.006001, 5.007003) ], 19 [ qw(Test::Harness::Assert Test::Harness::Straps) ], 20 'qr/Test::H.*::.*s/ at 5.006001 and 5.007003'); 21 22is_deeply([ Module::CoreList::find_modules(qr/Module::CoreList/) ], 23 [ qw(Module::CoreList Module::CoreList::TieHashDelta Module::CoreList::Utils) ], 24 'Module::CoreList functional' ); 25