MOON
Server: Apache
System: Linux vps.thepromohut.com 2.6.18-398.el5 #1 SMP Tue Sep 16 20:51:48 EDT 2014 i686
User: caretrak (507)
PHP: 5.2.10
Disabled: NONE
Upload Files
File: /home/.cpanm/work/1444124875.23915/local-lib-2.000017/t/de-dup.t
use strict;
use warnings;
use Test::More tests => 2;
use lib 't/lib';
use TempDir;
use Cwd;

my $dir = mk_temp_dir('test_local_lib-XXXXX');

use local::lib ();

my %inc;
my %perl5lib;

$inc{$_}--      for @INC;
$perl5lib{$_}-- for split /:/, $ENV{PERL5LIB};

local::lib->import($dir);
local::lib->import($dir);

$inc{$_}++      for @INC;
$perl5lib{$_}++ for split /:/, $ENV{PERL5LIB};

ok ! (grep { $inc{$_} > 1 } keys %inc), '@INC entries not duplicated';
ok ! (grep { $perl5lib{$_} > 1 } keys %perl5lib), 'ENV{PERL5LIB} entries not duplicated';