shopware / development

MIT License
189 stars 170 forks source link

Add support to mock the filesystem in integration tests #145

Closed niklasbuechner closed 3 years ago

niklasbuechner commented 3 years ago

The Shopware administration is unable to load a bundle's resources (CSS & JS) if the bundle's name contains bundle. In order to write an integration test for this case, you need to mock the file access of php's internal functions such as file_exists. The mikey179/vfsstream package allows you to do just that (For usage see: https://github.com/shopware/platform/pull/1607).

The package needs to be added to the development template since the platform's shopware installation does not install the development dependencies of the platform repository.

This pr adds the package here so that the integration tests in the https://github.com/shopware/platform repository can mock the internal filesystem.

CLAassistant commented 3 years ago

CLA assistant check
All committers have signed the CLA.

philipreinken commented 3 years ago

Just as a reference - a different solution has been implemented, so I'm closing this now: https://github.com/shopware/platform/pull/1607#issuecomment-777458321