Filesystem: Allow wp_normalise_path() to handle PHP stream wrappers such as php:// correctly.

Props calin, dd32.
Fixes #42837.


git-svn-id: https://develop.svn.wordpress.org/trunk@42387 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dion Hulse
2017-12-12 04:15:54 +00:00
parent f8dbb79a13
commit da689558a5
2 changed files with 19 additions and 1 deletions
+5
View File
@@ -150,6 +150,11 @@ class Tests_Functions extends WP_UnitTestCase {
array( '/www/path/', '/www/path/' ),
array( '/www/path/////', '/www/path/' ),
array( '/www/path', '/www/path' ),
// PHP Stream wrappers
array( 'php://input', 'php://input' ),
array( 'http://example.com//path.ext', 'http://example.com/path.ext' ),
array( 'file://c:\\www\\path\\', 'file://C:/www/path/' ),
);
}