Mercurial > hg > cmmr2012-drupal-site
comparison core/tests/Drupal/Tests/TestFileCreationTrait.php @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | c75dbcec494b |
children |
comparison
equal
deleted
inserted
replaced
4:a9cd425dd02b | 5:12f9dff5fda9 |
---|---|
69 | 69 |
70 // Copy other test files from simpletest. | 70 // Copy other test files from simpletest. |
71 $original = drupal_get_path('module', 'simpletest') . '/files'; | 71 $original = drupal_get_path('module', 'simpletest') . '/files'; |
72 $files = file_scan_directory($original, '/(html|image|javascript|php|sql)-.*/'); | 72 $files = file_scan_directory($original, '/(html|image|javascript|php|sql)-.*/'); |
73 foreach ($files as $file) { | 73 foreach ($files as $file) { |
74 file_unmanaged_copy($file->uri, PublicStream::basePath()); | 74 \Drupal::service('file_system')->copy($file->uri, PublicStream::basePath()); |
75 } | 75 } |
76 | 76 |
77 $this->generatedTestFiles = TRUE; | 77 $this->generatedTestFiles = TRUE; |
78 } | 78 } |
79 | 79 |