Bug #39715

FAL Unit tests produce failures and errors on Windows

Added by Jigal van Hemert over 9 years ago. Updated almost 7 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
File Abstraction Layer (FAL)
Target version:
-
Start date:
2012-08-12
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.0
PHP Version:
5.3
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Testsuite: t3lib_extFileFunctionsTest

deleteFileInLocalStorage
! Error in test case deleteFileInLocalStorage
File: D:\webserver\xampp\htdocs\typo3_src\t3lib\file\Driver\LocalDriver.php
Line: 993
File /\/_unitTestedFile.txt is not valid (".." and "//" is not allowed in path).

renameFileInLocalStorage
! Error in test case renameFileInLocalStorage
File: D:\webserver\xampp\htdocs\typo3_src\t3lib\file\Driver\LocalDriver.php
Line: 993
File \/_unitTestedFileRenamed.txt is not valid (".." and "//" is not allowed in path).

Testsuite: t3lib_file_Driver_LocalDriverTest

getFileReturnsCorrectIdentifier
Failure in test case getFileReturnsCorrectIdentifier
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\file\Driver\LocalDriverTest.php
Line: 616
Failed asserting that two strings are equal.
'/\/someFileAtRootLevel'

filesCanBeCopiedToATemporaryPath
Failure in test case filesCanBeCopiedToATemporaryPath
File: D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\PEAR\PHPUnit\Framework\Constraint.php
Line: 92
Failed asserting that 'D:\webserver\xampp\htdocs\typo3temp\fal2333.tmp.' contains "/typo3temp/".

permissionsAreCorrectlyRetrieved
Failure in test case permissionsAreCorrectlyRetrieved
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\file\Driver\LocalDriverTest.php
Line: 971
Failed asserting that two arrays are equal.
Array ( 'r' =>true 'w' =>false )

getFilePermissionsReturnsCorrectPermissionsForFilesNotOwnedByCurrentUser with data set "arbitrary group, readable/writable"
Failure in test case getFilePermissionsReturnsCorrectPermissionsForFilesNotOwnedByCurrentUser with data set "arbitrary group, readable/writable"
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\file\Driver\LocalDriverTest.php
Line: 1044
Failed asserting that two arrays are equal.
Array ( 'r' =>false 'w' =>false )

getFilePermissionsReturnsCorrectPermissionsForFilesNotOwnedByCurrentUser with data set "arbitrary group, readable/not writable"
Failure in test case getFilePermissionsReturnsCorrectPermissionsForFilesNotOwnedByCurrentUser with data set "arbitrary group, readable/not writable"
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\file\Driver\LocalDriverTest.php
Line: 1044
Failed asserting that two arrays are equal.
Array ( 'r' =>true 'w' =>true )

getFilePermissionsReturnsCorrectPermissionsForFilesNotOwnedByCurrentUser with data set "arbitrary group, not readable/not writable"
Failure in test case getFilePermissionsReturnsCorrectPermissionsForFilesNotOwnedByCurrentUser with data set "arbitrary group, not readable/not writable"
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\file\Driver\LocalDriverTest.php
Line: 1044
Failed asserting that two arrays are equal.
Array ( 'r' =>true 'w' =>true )

renamingFilesChangesFilenameOnDisk with data set "file in rootfolder"
! Error in test case renamingFilesChangesFilenameOnDisk with data set "file in rootfolder"
File: D:\webserver\xampp\htdocs\typo3_src\t3lib\file\Driver\LocalDriver.php
Line: 978
Renaming file vfs://base-50276b276d4cf/mount-50276b276d4c4/fileInRoot to vfs://base-50276b276d4cf/mount-50276b276d4c4//\/newFile failed.

renamingFoldersChangesFolderNameOnDisk with data set "folder in root folder"
! Error in test case renamingFoldersChangesFolderNameOnDisk with data set "folder in root folder"
File: D:\webserver\xampp\htdocs\typo3_src\t3lib\file\Driver\LocalDriver.php
Line: 1019
Renaming folder "vfs://base-50276b277c7fb/mount-50276b277c7f1/someFolder/" to "vfs://base-50276b277c7fb/mount-50276b277c7f1/\/newFolder/" failed."

renameFolderReturnsCorrectMappingInformationForAllFiles
! Error in test case renameFolderReturnsCorrectMappingInformationForAllFiles
File: D:\webserver\xampp\htdocs\typo3_src\t3lib\file\Driver\LocalDriver.php
Line: 1019
Renaming folder "vfs://base-50276b2783a7b/mount-50276b2783a70/sourceFolder/" to "vfs://base-50276b2783a7b/mount-50276b2783a70/\/newFolder/" failed."

renameFolderRevertsRenamingIfFilenameMapCannotBeCreated
Failure in test case renameFolderRevertsRenamingIfFilenameMapCannotBeCreated
File: D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\PEAR\PHPUnit\Framework\Constraint.php
Line: 92
Failed asserting that 1320375116 is equal to expected exception code 1334160746.

moveFolderWithinStorageReturnsCorrectMappingInformationForAllFiles
Failure in test case moveFolderWithinStorageReturnsCorrectMappingInformationForAllFiles
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\file\Driver\LocalDriverTest.php
Line: 1468
Failed asserting that null matches expected '/targetFolder/sourceFolder/subFolder/file'.

Testsuite: t3lib_utility_PathTest

isCommonPrefixResolvedCorrectly with data set #0
Failure in test case isCommonPrefixResolvedCorrectly with data set #0
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 45
Failed asserting that two strings are equal.
'/var/www/myhost.com/t3lib/\'

isCommonPrefixResolvedCorrectly with data set #1
Failure in test case isCommonPrefixResolvedCorrectly with data set #1
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 45
Failed asserting that two strings are equal.
'/var/www/myhost.com/t3lib/\'

isCommonPrefixResolvedCorrectly with data set #2
Failure in test case isCommonPrefixResolvedCorrectly with data set #2
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 45
Failed asserting that null matches expected '/var/www/myhost.com/'.

isCommonPrefixResolvedCorrectly with data set #3
Failure in test case isCommonPrefixResolvedCorrectly with data set #3
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 45
Failed asserting that null matches expected '/var/www/myhost.com/'.

isCommonPrefixResolvedCorrectly with data set #4
Failure in test case isCommonPrefixResolvedCorrectly with data set #4
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 45
Failed asserting that null matches expected '/var/www/myhost.com/'.

isRelativePathResolvedCorrectly with data set #2
Failure in test case isRelativePathResolvedCorrectly with data set #2
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 102
Failed asserting that null matches expected '../t3lib/'.

isRelativePathResolvedCorrectly with data set #3
Failure in test case isRelativePathResolvedCorrectly with data set #3
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 102
Failed asserting that null matches expected 't3lib/'.

isRelativePathResolvedCorrectly with data set #4
Failure in test case isRelativePathResolvedCorrectly with data set #4
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 102
Failed asserting that null matches expected 'stddb/'.

isRelativePathResolvedCorrectly with data set #5
Failure in test case isRelativePathResolvedCorrectly with data set #5
File: D:\TYPO3\TYPO3 Core Git\tests\Unit\t3lib\utility\class.t3lib_utility_pathTest.php
Line: 102
Failed asserting that null matches expected '../../../t3lib/utility/'.

#1

Updated by Andreas Wolf about 9 years ago

  • Status changed from New to Accepted
#2

Updated by Nicole Cordes over 8 years ago

  • Assignee set to Nicole Cordes
  • Target version changed from 6.0.0-pre-beta1 to next-patchlevel
#3

Updated by Jigal van Hemert over 8 years ago

Testsuite: TYPO3\CMS\Core\Tests\Unit\Utility\File\ExtendedFileUtilityTest

Rename file in local storage
Failure in test case renameFileInLocalStorage
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Tests\Functional\Utility\File\ExtendedFileUtilityTest.php
Line: 276
Failed asserting that false matches expected true.

Testsuite: TYPO3\CMS\Core\Tests\Functional\Resource\FolderTest

Get files respects set file and foldername filters if filter mode is use own filters
Failure in test case getFilesRespectsSetFileAndFoldernameFiltersIfFilterModeIsUseOwnFilters
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that actual size 0 matches expected size 2.

Get files merges set file and foldername filters into storages filters if filter mode is use own and storage filters
Failure in test case getFilesMergesSetFileAndFoldernameFiltersIntoStoragesFiltersIfFilterModeIsUseOwnAndStorageFilters
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that actual size 0 matches expected size 1.

Get files uses only file and foldername filters of storage if no filters are set and filter mode is use own and storage filters
Failure in test case getFilesUsesOnlyFileAndFoldernameFiltersOfStorageIfNoFiltersAreSetAndFilterModeIsUseOwnAndStorageFilters
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that actual size 0 matches expected size 2.

Get files ignores set file and foldername filters if filter mode is set to use storage filters
Failure in test case getFilesIgnoresSetFileAndFoldernameFiltersIfFilterModeIsSetToUseStorageFilters
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that actual size 0 matches expected size 3.

Get subfolders respects set file and foldername filters if filter mode is use own filters
Failure in test case getSubfoldersRespectsSetFileAndFoldernameFiltersIfFilterModeIsUseOwnFilters
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that actual size 0 matches expected size 2.

Testsuite: TYPO3\CMS\Core\Tests\Functional\Resource\ResourceStorageTest

File listings do not contain hidden files with default filters
Failure in test case fileListingsDoNotContainHiddenFilesWithDefaultFilters
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that an array contains 'someFile'.

Folder listings do not contain hidden folders by default
Failure in test case folderListingsDoNotContainHiddenFoldersByDefault
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php
Line: 91
Failed asserting that an array contains 'someFolder'.

Testsuite: TYPO3\CMS\Core\Tests\Unit\Resource\Driver\LocalDriverTest

Created files are empty
! Error in test case createdFilesAreEmpty
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Classes\Resource\Driver\LocalDriver.php
Line: 1171
file_get_contents(D:/webserver/xampp/htdocs/typo3temp/fal-test-5200de1a84043/): failed to open stream: No such file or directory

Get file list returns all files in directory
Failure in test case getFileListReturnsAllFilesInDirectory
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Tests\Unit\Resource\Driver\LocalDriverTest.php
Line: 740
Failed asserting that two arrays are equal.
Array ( )

Get file list returns all files in subdirectory if recursive parameter is set
Failure in test case getFileListReturnsAllFilesInSubdirectoryIfRecursiveParameterIsSet
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Tests\Unit\Resource\Driver\LocalDriverTest.php
Line: 765
Failed asserting that two arrays are equal.
Array ( 0 =>'aDir/subdir/file4' 1 =>'aDir/file3' )

Get folder list returns all directories in directory
Failure in test case getFolderListReturnsAllDirectoriesInDirectory
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Tests\Unit\Resource\Driver\LocalDriverTest.php
Line: 857
Failed asserting that two arrays are equal.
Array ( )

Get folder list returns hidden folders by default
Failure in test case getFolderListReturnsHiddenFoldersByDefault
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Tests\Unit\Resource\Driver\LocalDriverTest.php
Line: 876
Failed asserting that two arrays are equal.
Array ( )

Get folder list uses correct path for items
Failure in test case getFolderListUsesCorrectPathForItems
File: D:\TYPO3\TYPO3 Core Git\typo3\sysext\core\Tests\Unit\Resource\Driver\LocalDriverTest.php
Line: 892
Failed asserting that null matches expected '/dir1/'.

Testsuite: TYPO3\CMS\Core\Tests\Unit\Resource\FactoryTest

Retrieve file or folder object returns folder if path is given with data set "relative path"
Failure in test case retrieveFileOrFolderObjectReturnsFolderIfPathIsGiven with data set "relative path"
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit-mock-objects\PHPUnit\Framework\MockObject\InvocationMocker.php
Line: 198
Expectation failed for method name is equal to <string:getFolder> when invoked 1 time(s).
Method was expected to be called 1 times, actually called 0 times.

retrieveFileOrFolderObjectReturnsFolderIfPathIsGiven with data set "path with PATH site"
Failure in test case retrieveFileOrFolderObjectReturnsFolderIfPathIsGiven with data set "path with PATH_site"
File: D:\TYPO3\TYPO3 extensions\phpunit\Composer\vendor\phpunit\phpunit-mock-objects\PHPUnit\Framework\MockObject\InvocationMocker.php
Line: 198
Expectation failed for method name is equal to <string:getFolder> when invoked 1 time(s).
Method was expected to be called 1 times, actually called 0 times.

#4

Updated by Steffen Ritter over 7 years ago

  • Status changed from Accepted to Needs Feedback
  • Assignee deleted (Nicole Cordes)
  • Is Regression set to No

still valid?

#5

Updated by Jigal van Hemert over 7 years ago

Ran the 'Resource' tests on PhpStorm:

D:\webserver\xampp\php\php.exe C:\Users\Maarten\AppData\Local\Temp\ide-phpunit.php --bootstrap D:\typo3\TYPO3_Master\typo3\sysext\core\Build\UnitTestsBootstrap.php --no-configuration D:\typo3\TYPO3_Master\typo3\sysext\core\Tests\Unit\Resource
Testing started at 21:00 ...
PHPUnit 3.7.22 by Sebastian Bergmann.

PHPUnit_Framework_ExpectationFailedException : Failed asserting that true is false.
#0 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Constraint.php(91): PHPUnit_Framework_Constraint->fail(true, '')
#1 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Assert.php(2134): PHPUnit_Framework_Constraint->evaluate(true, '')
#2 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\Assert.php(900): PHPUnit_Framework_Assert::assertThat(true, Object(PHPUnit_Framework_Constraint_IsFalse), '')
#3 D:\typo3\TYPO3_Master\typo3\sysext\core\Tests\Unit\Resource\Driver\DriverRegistryTest.php(124): PHPUnit_Framework_Assert::assertFalse(true)
#4 [internal function]: TYPO3\CMS\Core\Tests\Unit\Resource\Driver\DriverRegistryTest->driverExistsReturnsTrueForAllExistingDrivers()
#5 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestCase.php(976): ReflectionMethod->invokeArgs(Object(TYPO3\CMS\Core\Tests\Unit\Resource\Driver\DriverRegistryTest), Array)
#6 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestCase.php(831): PHPUnit_Framework_TestCase->runTest()
#7 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestResult.php(648): PHPUnit_Framework_TestCase->runBare()
#8 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestCase.php(776): PHPUnit_Framework_TestResult->run(Object(TYPO3\CMS\Core\Tests\Unit\Resource\Driver\DriverRegistryTest))
#9 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestSuite.php(775): PHPUnit_Framework_TestCase->run(Object(PHPUnit_Framework_TestResult))
#10 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestSuite.php(745): PHPUnit_Framework_TestSuite->runTest(Object(TYPO3\CMS\Core\Tests\Unit\Resource\Driver\DriverRegistryTest), Object(PHPUnit_Framework_TestResult))
#11 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\Framework\TestSuite.php(705): PHPUnit_Framework_TestSuite->run(Object(PHPUnit_Framework_TestResult), false, Array, Array, false)
#12 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\TextUI\TestRunner.php(349): PHPUnit_Framework_TestSuite->run(Object(PHPUnit_Framework_TestResult), false, Array, Array, false)
#13 D:\webserver\xampp\htdocs\typo3conf\ext\phpunit\Composer\vendor\phpunit\phpunit\PHPUnit\TextUI\Command.php(176): PHPUnit_TextUI_TestRunner->doRun(Object(PHPUnit_Framework_TestSuite), Array)
#14 C:\Users\Maarten\AppData\Local\Temp\ide-phpunit.php(268): PHPUnit_TextUI_Command->run(Array, true)
#15 C:\Users\Maarten\AppData\Local\Temp\ide-phpunit.php(506): IDE_Base_PHPUnit_TextUI_Command::main()
#16 {main}

[[[[..... info on skipped tests .....]]]]

Time: 2 seconds, Memory: 23.75Mb

FAILURES!
Tests: 232, Assertions: 479, Failures: 1, Skipped: 29.

Process finished with exit code 1

#6

Updated by Alexander Opitz over 7 years ago

Hi Jigal,

does all tests running on windows now?

#7

Updated by Alexander Opitz almost 7 years ago

  • Status changed from Needs Feedback to Closed
  • Target version deleted (next-patchlevel)

No feedback within the last 90 days => closing this issue.

If you think that this is the wrong decision or experience this issue again, then please write to the mailing list typo3.teams.bugs with issue number and an explanation or open a new ticket and add a relation to this ticket number.

Also available in: Atom PDF