Update CPANPLUS to 0.85_06
[p5sagit/p5-mst-13.2.git] / lib / CPANPLUS / t / 20_CPANPLUS-Dist-MM.t
index 315cea6..d3eb525 100644 (file)
@@ -129,16 +129,6 @@ SKIP: {
     skip(q[No install tests under core perl],            10) if $ENV{PERL_CORE};
     skip(q[Possibly no permission to install, skipping], 10) if $noperms;
 
-    ### XXX new EU::I should be forthcoming pending this patch from Steffen
-    ### Mueller on p5p: http://www.xray.mpe.mpg.de/mailing-lists/ \ 
-    ###     perl5-porters/2007-01/msg00895.html
-    ### This should become EU::I 1.42.. if so, we should upgrade this bit of
-    ### code and remove the diag, since we can then install in our dummy dir..
-    diag("\nSorry, installing into your real perl dir, rather than our test");
-    diag("area since ExtUtils::Installed does not probe for .packlists in " );
-    diag('other dirs than those in %Config. See bug #6871 on rt.cpan.org ' );
-    diag('for details');
-
     ### we now say 'no perms' if sudo is configured, as per #29904
     #diag(q[Note: 'sudo' might ask for your password to do the install test])
     #    if $conf->get_program('sudo');
@@ -151,17 +141,19 @@ SKIP: {
     ### include INSTALL_BASE
     {   local $ENV{'PERL5_MM_OPT'};
     
-        ok( $Mod->install( force =>1 ),
-                                "Installing module" );
+        ### add the new dir to the configuration too, so eu::installed tests
+        ### work as they should
+        $conf->set_conf( lib => [ TEST_CONF_INSTALL_DIR ] );
+    
+        ok( $Mod->install(  force           => 1, 
+                            makemakerflags  => 'PREFIX='.TEST_CONF_INSTALL_DIR, 
+                        ),      "Installing module" );
     }                                
                                 
     ok( $Mod->status->installed,"   Module installed according to status" );
 
 
     SKIP: {   ### EU::Installed tests ###
-
-        skip("makemakerflags set -- probably EU::Installed tests will fail", 8)
-           if $conf->get_conf('makemakerflags');
     
         skip( "Old perl on cygwin detected " .
               "-- tests will fail due to known bugs", 8
@@ -221,9 +213,8 @@ SKIP: {
 
 ### test exceptions in Dist::MM->create ###
 {   ok( $Mod->status->mk_flush, "Old status info flushed" );
-    my $dist = CPANPLUS::Dist->new( module => $Mod,
-                                    format => INSTALLER_MM );
-
+    my $dist = INSTALLER_MM->new( module => $Mod );
+    
     ok( $dist,                  "New dist object made" );
     ok(!$dist->prepare,         "   Dist->prepare failed" );
     like( CPANPLUS::Error->stack_as_string, qr/No dir found to operate on/,