Source

perl-File-Find-Object / t / 05prune.t

Diff from to

File t/05prune.t

             {
                 'name' => "b.doc",
                 'contents' => "This file was spotted in the wild.",
-            },            
+            },
             {
                 'name' => "a/",
             },
                                         'name' => "dir2/",
                                     },
                                     {
-                                        'name' => 
+                                        'name' =>
                                             "if-we-get-this-its-wrong.txt",
                                         'content' => "Hi ho!",
                                     },
                                 ],
-                            },                        
+                            },
                             {
                                 'name' => "h.rnd",
                                 'contents' => "This file is empty.",
 
     my $t = File::Find::Object::TreeCreate->new();
     $t->create_tree("./t/sample-data/", $tree);
-    my $ff = 
+    my $ff =
         File::Find::Object->new(
             {},
             $t->get_path("./t/sample-data/traverse-2")
         # We're doing that because get_current_node_files_list() used to
         # call ->_recurse() which caused some subtle bugs.
         my $files_in_node = $ff->get_current_node_files_list();
-        
+
         if ($file eq
             $t->get_path("t/sample-data/traverse-2/foo/please-prune-me")
            )
         {
             $ff->set_traverse_to(
                 [
-                    grep { $_ !~ /non-reachable/ } 
+                    grep { $_ !~ /non-reachable/ }
                     @{$ff->get_current_node_files_list()}
                 ]
             );
     is_deeply(
         \@results,
         [(map { $t->get_path("t/sample-data/traverse-2/$_") }
-            ("", 
+            ("",
             qw(
                 a
                 b.doc
             {
                 'name' => "b.doc",
                 'contents' => "This file was spotted in the wild.",
-            },            
+            },
             {
                 'name' => "a/",
             },
                                         'name' => "dir2/",
                                     },
                                     {
-                                        'name' => 
+                                        'name' =>
                                             "if-we-get-this-its-wrong.txt",
                                         'content' => "Hi ho!",
                                     },
                                 ],
-                            },                        
+                            },
                             {
                                 'name' => "h.rnd",
                                 'contents' => "This file is empty.",
 
     my $t = File::Find::Object::TreeCreate->new();
     $t->create_tree("./t/sample-data/", $tree);
-    my $ff = 
+    my $ff =
         File::Find::Object->new(
             {},
             $t->get_path("./t/sample-data/traverse-2")
     for my $i (1 .. 9)
     {
         my $file = $ff->next();
-        if ($file eq 
+        if ($file eq
             $t->get_path("t/sample-data/traverse-2/foo/please-prune-me")
            )
         {
     is_deeply(
         \@results,
         [(map { $t->get_path("t/sample-data/traverse-2/$_") }
-            ("", 
+            ("",
             qw(
                 a
                 b.doc