Index: gs2-extensions/parallel-building/trunk/src/bin/script/test_fileutils.pl
===================================================================
--- gs2-extensions/parallel-building/trunk/src/bin/script/test_fileutils.pl	(revision 27479)
+++ gs2-extensions/parallel-building/trunk/src/bin/script/test_fileutils.pl	(revision 27480)
@@ -7,11 +7,10 @@
 # Configure
 my $user = 'jmt12';
-my $hadoop_path = '/mnt/sdb1/jmt12/gsdl2-svn/ext/parallel-building/packages/hadoop-1.1.0';
 my $redirect_errors = 0;
 my $display_errors = 0;
 
-my $test_localfs = 0;
+my $test_localfs = 1;
 my $test_hdthriftfs = 1;
-my $test_hdfsshell = 0;
+my $test_hdfsshell = 1;
 
 # Globals
@@ -49,8 +48,17 @@
     }
   }
+
+  # Manually installed CPAN package in GEXT*INSTALL
+  # - parse up version number
+  my ($major, $minor, $revision) = $] =~ /(\d+)\.(\d\d\d)(\d\d\d)/;
+  # - get rid of leading zeros by making them integers
+  $major += 0;
+  $minor += 0;
+  $revision += 0;
+  # - and add to Perl's path
+  unshift (@INC, $ENV{'GEXTPARALLELBUILDING_INSTALLED'} . '/lib/perl/' . $major . '.' . $minor . '.' . $revision);
 }
 
 use Cwd;
-use DateTime;
 use Devel::Peek;
 
@@ -58,5 +66,5 @@
 
 # populate globals
-$base_path = getcwd();
+$base_path = $ENV{'GEXTPARALLELBUILDING'};
 
 print "\n";
@@ -255,5 +263,5 @@
   my ($dir, $base_dir) = @_;
   # setup
-  my $local_image_path = $base_path . '/../../resources/aurora_australus.jpg';
+  my $local_image_path = $base_path . '/resources/aurora_australus.jpg';
   my $thrift_copy_path = $dir . '/test_binary_transfer.jpg';
   my $local_copy_path = '/tmp/test_binary_transfer.jpg';
@@ -464,46 +472,11 @@
 {
   my ($dir) = @_;
+  # setup
   my $patha = $dir . '/alpha.txt';
-  my $exact_modification_time = time();
-  #rint STDERR "Exact Modification Time:  $exact_modification_time\n";
+  my $modification_time = time();
   &FileUtils::filePutContents($patha, 'Hello World');
   my $file_modification_time = &FileUtils::modificationTime($patha);
-  #rint STDERR "File Modification Time:   $file_modification_time\n";
-  # Try to find an exact match first
-  if ($exact_modification_time == $file_modification_time)
-  {
-    $pass_count += &testAction(\$test_count, 'modificationTime() to determine the last modified time as a linux epoc (exact)', 1, 1);
-  }
-  # Failing that, we can try a rounded match (for file systems that
-  # don't store modification times down to the second i.e. HDFSShell)
-  else
-  {
-    $skip_count += &skipAction(\$test_count, 'modificationTime() to determine the last modified time as a linux epoc (exact)');
-    my ($mod_second, $mod_minute, $mod_hour, $mod_day, $mod_month, $mod_year) = localtime($exact_modification_time);
-    $mod_year += 1900; # initially years since 1900, silly computer scientists
-    $mod_month += 1; # in the range [0..11], silly computer scientists
-    my $mod_datetime = DateTime->new(year      => $mod_year,
-                                     month     => $mod_month,
-                                     day       => $mod_day,
-                                     hour      => $mod_hour,
-                                     minute    => $mod_minute,
-                                     second    => 0,
-                                     time_zone => 'local');
-    my $start_modification_time = $mod_datetime->epoch();
-    #rint STDERR "Start Modification Time: $start_modification_time\n";
-    if ($start_modification_time == $file_modification_time)
-    {
-      $pass_count += &testAction(\$test_count, 'modificationTime() to determine the last modified time as a linux epoc (rounded)', 1, 1);
-    }
-    # And finally we just accept any time that lies within the same minute
-    else
-    {
-      $skip_count += &skipAction(\$test_count, 'modificationTime() to determine the last modified time as a linux epoc (rounded)');
-      $mod_datetime->add( minutes => 1 );
-      my $end_modification_time = $mod_datetime->epoch();
-      #rint STDERR "End Modification Time: $end_modification_time\n";
-      $pass_count += &testAction(\$test_count, 'modificationTime() to determine the last modified time as a linux epoc (approximate)', 1, ($start_modification_time <= $file_modification_time && $file_modification_time <= $end_modification_time ? 1 : 0));
-    }
-  }
+  # test
+  $pass_count += &testAction(\$test_count, 'modificationTime() to determine the last modified time as a linux epoc', $modification_time, $file_modification_time);
   # cleanup
   &FileUtils::removeFiles($patha);
