joomla/joomla-cms — pull request #3880 by Hackwar (2014-07-11 13:55:21+00:00)
Title: Fixing several unittests on Windows

This fixes 6 test-failures on my windows machine.

1. JArchiveBzip2Test: I'm wondering how this has ever worked. BZIP2 as a compression algorithm can only (de-)compress single files and the filename of the archive represents the filename of the uncompressed file. The way this was done up till now, it was not possible to successfully test that the file was decompressed...

2. JArchiveTest: Again, this was unable to work properly the way it was done. It uncompressed the archive into a folder named $output.'/logo-something.png/', maybe succeeding, maybe not. While I remember, that is_file() returns true if a file OR FOLDER with that name exists, that apparently seems to be wrong. But in the end, this means that the file is decompressed into that subfolder and the subsequent check fails, resulting in the file not being removed after the test is done. unlink() does not work on folders, but only on files.

3. JCacheStorageTest: The 60 seconds are simply the default value. If you have something else set in your configuration.php, this will fail.

4. JViewLegacyTest: Simply fixing a few slashes...