diff --git a/core/modules/system/system.test b/core/modules/system/system.test
index 4e3761d..2a28393 100644
--- a/core/modules/system/system.test
+++ b/core/modules/system/system.test
@@ -1622,7 +1622,7 @@ class SystemThemeFunctionalTest extends DrupalWebTestCase {
   function testThemeSettings() {
     // Specify a filesystem path to be used for the logo.
     $file = current($this->drupalGetTestFiles('image'));
-    $fullpath = drupal_realpath($file->uri);
+    $fullpath = strtr($file->uri, array('public:/' => variable_get('file_public_path', conf_path() . '/files')));
     $edit = array(
       'default_logo' => FALSE,
       'logo_path' => $fullpath,
