? ? Pending

User tests: Successful: Unsuccessful:

avatar fastslack
fastslack
8 Jan 2018

Summary of Changes

Moved all libraries names to use namespace

Testing Instructions

Use as usual, all should work fine.

Expected result

No errors

avatar fastslack fastslack - open - 8 Jan 2018
avatar fastslack fastslack - change - 8 Jan 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 8 Jan 2018
Category Libraries
avatar fastslack fastslack - change - 8 Jan 2018
Title
Filesystem namespace
[3.9] Filesystem namespace
avatar fastslack fastslack - edited - 8 Jan 2018
avatar fastslack fastslack - change - 8 Jan 2018
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - change - 8 Jan 2018
Category Libraries Libraries Unit Tests
avatar fastslack fastslack - change - 8 Jan 2018
Labels Added: ?
avatar laoneo
laoneo - comment - 11 Jan 2018

There are still unit tests failing. Can you fix them please.

avatar fastslack
fastslack - comment - 11 Jan 2018

@laoneo @mbabker Im still having the same issue. Test fail is

1) JFilesystemHelperTest::testGetJStreams
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
 Array (
-    0 => 'string'
+    0 => 'String'
 )
C:\projects\joomla-cms\tests\unit\suites\libraries\joomla\filesystem\JFilesystemHelperTest.php:65

But if i change that file, i still having testing issues. Any idea?

avatar laoneo
laoneo - comment - 1 Feb 2018

There are some other errors, please apply the patch on your branch. Then the tests should pass and we can get that in.

Index: libraries/src/Filesystem/Streams/String.php
===================================================================
--- libraries/src/Filesystem/Streams/String.php	(date 1515624926000)
+++ libraries/src/Filesystem/Streams/StreamString.php	(date 1517480939000)
@@ -290,4 +290,4 @@
 	}
 }
 
-stream_wrapper_register('string', 'StreamString') or die('StreamString Wrapper Registration Failed');
+stream_wrapper_register('string', '\\Joomla\\CMS\\Filesystem\\Streams\\StreamString') or die('StreamString Wrapper Registration Failed');
Index: libraries/src/Filesystem/Support/Stringcontroller.php
===================================================================
--- libraries/src/Filesystem/Support/Stringcontroller.php	(date 1515624926000)
+++ libraries/src/Filesystem/Support/StringController.php	(date 1517480969000)
@@ -15,7 +15,7 @@
  *
  * @since  11.1
  */
-class Stringcontroller
+class StringController
 {
 	/**
 	 * Defines a variable as an array
Index: libraries/src/Filesystem/FilesystemHelper.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- libraries/src/Filesystem/FilesystemHelper.php	(date 1515624926000)
+++ libraries/src/Filesystem/FilesystemHelper.php	(date 1517481315000)
@@ -274,7 +274,7 @@
 					continue;
 				}
 
-				$streams[] = $file->getBasename('.php');
+				$streams[] = str_replace('stream', '', strtolower($file->getBasename('.php')));
 			}
 		}
 
Index: libraries/classmap.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- libraries/classmap.php	(date 1515624926000)
+++ libraries/classmap.php	(date 1517481181000)
@@ -431,6 +431,6 @@
 JLoader::registerAlias('JStream',                           '\\Joomla\\CMS\\Filesystem\\Stream', '5.0');
 JLoader::registerAlias('JStreamString',                     '\\Joomla\\CMS\\Filesystem\\Streams\\StreamString', '5.0');
 JLoader::registerAlias('JStringController',                 '\\Joomla\\CMS\\Filesystem\\Support\\StringController', '5.0');
-JLoader::registerAlias('JFilesystemWrapperFile',            '\\Joomla\\CMS\\Filesystem\\FileWrapper', '5.0');
-JLoader::registerAlias('JFilesystemWrapperFolder',          '\\Joomla\\CMS\\Filesystem\\FolderWrapper', '5.0');
-JLoader::registerAlias('JFilesystemWrapperPath',            '\\Joomla\\CMS\\Filesystem\\PathWrapper', '5.0');
+JLoader::registerAlias('JFilesystemWrapperFile',            '\\Joomla\\CMS\\Filesystem\\Wrapper\\FileWrapper', '5.0');
+JLoader::registerAlias('JFilesystemWrapperFolder',          '\\Joomla\\CMS\\Filesystem\\Wrapper\\FolderWrapper', '5.0');
+JLoader::registerAlias('JFilesystemWrapperPath',            '\\Joomla\\CMS\\Filesystem\\Wrapper\\PathWrapper', '5.0');
avatar laoneo
laoneo - comment - 6 Feb 2018

@wilsonge can we merge this one? Will fix the tests then in a second step.

avatar laoneo
laoneo - comment - 26 Mar 2018

@wilsonge can we merge this one? Will fix the tests then in a second step.

avatar fastslack
fastslack - comment - 27 Mar 2018

@laoneo @wilsonge Sorry i tried lot of things to fix this without any result

avatar laoneo laoneo - change - 4 Apr 2018
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2018-04-04 06:37:36
Closed_By laoneo
avatar laoneo laoneo - close - 4 Apr 2018
avatar laoneo laoneo - merge - 4 Apr 2018
avatar laoneo
laoneo - comment - 4 Apr 2018

Removed invalid file with c9f6849.

avatar zero-24
zero-24 - comment - 4 Apr 2018

@laoneo please use milestones. Thanks ?

avatar laoneo
laoneo - comment - 4 Apr 2018

Will do.

Add a Comment

Login with GitHub to post a comment